Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1caf8504 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: smem: Rename smem_find_to_proc() to smem_find()"

parents 1d77d770 985046c4
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -159,7 +159,7 @@ enum {
void *smem_get_entry(unsigned id, unsigned *size);
void *smem_alloc(unsigned id, unsigned size_in, unsigned to_proc,
								unsigned flags);
void *smem_find_to_proc(unsigned id, unsigned size_in, unsigned to_proc,
void *smem_find(unsigned id, unsigned size_in, unsigned to_proc,
								unsigned flags);
void *smem_get_entry_to_proc(unsigned id, unsigned *size, unsigned to_proc,
								unsigned flags);
@@ -208,7 +208,7 @@ void *smem_alloc(unsigned id, unsigned size_in, unsigned to_proc,
{
	return NULL;
}
static void *smem_find_to_proc(unsigned id, unsigned size_in, unsigned to_proc,
static void *smem_find(unsigned id, unsigned size_in, unsigned to_proc,
								unsigned flags)
{
	return NULL;
+1 −1
Original line number Diff line number Diff line
@@ -572,7 +572,7 @@ static int remote_spinlock_init_address_smem(int id, _remote_spinlock_t *lock)
	if (id >= SMEM_SPINLOCK_COUNT)
		return -EINVAL;

	spinlock_start = smem_find_to_proc(SMEM_SPINLOCK_ARRAY,
	spinlock_start = smem_find(SMEM_SPINLOCK_ARRAY,
				    SMEM_SPINLOCK_ARRAY_SIZE,
				    0,
				    SMEM_ANY_HOST_FLAG);
+2 −2
Original line number Diff line number Diff line
@@ -1267,7 +1267,7 @@ static int rmt_storage_get_ramfs(struct rmt_storage_srv *srv)
	if (srv->prog != MSM_RMT_STORAGE_APIPROG)
		return 0;

	ramfs_table = smem_find_to_proc(SMEM_SEFS_INFO,
	ramfs_table = smem_find(SMEM_SEFS_INFO,
			sizeof(struct shared_ramfs_table),
			0,
			SMEM_ANY_HOST_FLAG);
@@ -1444,7 +1444,7 @@ static int rmt_storage_init_ramfs(struct rmt_storage_srv *srv)
	if (srv->prog != MSM_RMT_STORAGE_APIPROG)
		return 0;

	ramfs_table = smem_find_to_proc(SMEM_SEFS_INFO,
	ramfs_table = smem_find(SMEM_SEFS_INFO,
				 sizeof(struct shared_ramfs_table),
				 0,
				 SMEM_ANY_HOST_FLAG);
+7 −8
Original line number Diff line number Diff line
@@ -544,8 +544,7 @@ void smd_diag(void)
	char *x;
	int size;

	x = smem_find_to_proc(ID_DIAG_ERR_MSG, SZ_DIAG_ERR_MSG, 0,
							SMEM_ANY_HOST_FLAG);
	x = smem_find(ID_DIAG_ERR_MSG, SZ_DIAG_ERR_MSG, 0, SMEM_ANY_HOST_FLAG);
	if (x != 0) {
		x[SZ_DIAG_ERR_MSG - 1] = 0;
		SMD_INFO("smem: DIAG '%s'\n", x);
@@ -982,11 +981,11 @@ static void smd_channel_reset_state(struct smd_alloc_elm *shared, int table_id,
		type = SMD_CHANNEL_TYPE(shared[n].type);
		is_word_access = is_word_access_ch(type);
		if (is_word_access)
			shared2 = smem_find_to_proc(base_id + n,
			shared2 = smem_find(base_id + n,
				sizeof(struct smd_shared_v2_word_access), pid,
				0);
		else
			shared2 = smem_find_to_proc(base_id + n,
			shared2 = smem_find(base_id + n,
				sizeof(struct smd_shared_v2), pid, 0);
		if (!shared2)
			continue;
@@ -1783,7 +1782,7 @@ static int smd_alloc_v2(struct smd_channel *ch, int table_id,

	if (is_word_access_ch(ch->type)) {
		struct smd_shared_v2_word_access *shared2;
		shared2 = smem_find_to_proc(base_id + ch->n, sizeof(*shared2),
		shared2 = smem_find(base_id + ch->n, sizeof(*shared2),
							r_info->remote_pid, 0);
		if (!shared2) {
			SMD_INFO("smem_find failed ch=%d\n", ch->n);
@@ -1793,7 +1792,7 @@ static int smd_alloc_v2(struct smd_channel *ch, int table_id,
		ch->recv = &shared2->ch1;
	} else {
		struct smd_shared_v2 *shared2;
		shared2 = smem_find_to_proc(base_id + ch->n, sizeof(*shared2),
		shared2 = smem_find(base_id + ch->n, sizeof(*shared2),
							r_info->remote_pid, 0);
		if (!shared2) {
			SMD_INFO("smem_find failed ch=%d\n", ch->n);
@@ -1839,7 +1838,7 @@ static int smd_alloc_v2(struct smd_channel *ch, int table_id,
static int smd_alloc_v1(struct smd_channel *ch)
{
	struct smd_shared_v1 *shared1;
	shared1 = smem_find_to_proc(ID_SMD_CHANNELS + ch->n, sizeof(*shared1),
	shared1 = smem_find(ID_SMD_CHANNELS + ch->n, sizeof(*shared1),
							0, SMEM_ANY_HOST_FLAG);
	if (!shared1) {
		pr_err("smd_alloc_channel() cid %d does not exist\n", ch->n);
@@ -2578,7 +2577,7 @@ static int smsm_init(void)
	}
	remote_spin_unlock_irqrestore(remote_spinlock, flags);

	smsm_size_info = smem_find_to_proc(SMEM_SMSM_SIZE_INFO,
	smsm_size_info = smem_find(SMEM_SMSM_SIZE_INFO,
				sizeof(struct smsm_size_info_type), 0,
				SMEM_ANY_HOST_FLAG);
	if (smsm_size_info) {
+2 −2
Original line number Diff line number Diff line
@@ -107,7 +107,7 @@ static void debug_read_smd_version(struct seq_file *s)
	uint32_t *smd_ver;
	uint32_t n, version;

	smd_ver = smem_find_to_proc(SMEM_VERSION_SMD, 32 * sizeof(uint32_t),
	smd_ver = smem_find(SMEM_VERSION_SMD, 32 * sizeof(uint32_t),
							0, SMEM_ANY_HOST_FLAG);

	if (smd_ver)
@@ -265,7 +265,7 @@ ID|CHANNEL NAME |T|PROC |STATE |FIFO SZ|RDPTR |WRPTR |FLAGS |DATAPEN
		else
			half_ch_size = sizeof(struct smd_half_channel);

		half_ch = smem_find_to_proc(ch_base_id + n, 2 * half_ch_size,
		half_ch = smem_find(ch_base_id + n, 2 * half_ch_size,
								pid, flags);
		buffer = smem_get_entry_to_proc(fifo_base_id + n, &buffer_size,
								pid, flags);
Loading