Skip to content

Commit 87dff4e

Browse files
cris-masudeep-holla
authored andcommitted
firmware: arm_scmi: Rename .clear_notification() transport_ops
SCMI transport operation .clear_notification() is indeed a generic method to clear the channel in a transport dependent way, as such it could be a useful helper also in other contexts. Rename such method as .clear_channel(), renaming accordingly also its already existent call-sites. No functional change. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Cristian Marussi <[email protected]> Signed-off-by: Sudeep Holla <[email protected]>
1 parent 4d09852 commit 87dff4e

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

drivers/firmware/arm_scmi/common.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ struct scmi_chan_info {
179179
* @mark_txdone: Callback to mark tx as done
180180
* @fetch_response: Callback to fetch response
181181
* @fetch_notification: Callback to fetch notification
182-
* @clear_notification: Callback to clear a pending notification
182+
* @clear_channel: Callback to clear a channel
183183
* @poll_done: Callback to poll transfer status
184184
*/
185185
struct scmi_transport_ops {
@@ -194,7 +194,7 @@ struct scmi_transport_ops {
194194
struct scmi_xfer *xfer);
195195
void (*fetch_notification)(struct scmi_chan_info *cinfo,
196196
size_t max_len, struct scmi_xfer *xfer);
197-
void (*clear_notification)(struct scmi_chan_info *cinfo);
197+
void (*clear_channel)(struct scmi_chan_info *cinfo);
198198
bool (*poll_done)(struct scmi_chan_info *cinfo, struct scmi_xfer *xfer);
199199
};
200200

@@ -232,6 +232,6 @@ void shmem_fetch_response(struct scmi_shared_mem __iomem *shmem,
232232
struct scmi_xfer *xfer);
233233
void shmem_fetch_notification(struct scmi_shared_mem __iomem *shmem,
234234
size_t max_len, struct scmi_xfer *xfer);
235-
void shmem_clear_notification(struct scmi_shared_mem __iomem *shmem);
235+
void shmem_clear_channel(struct scmi_shared_mem __iomem *shmem);
236236
bool shmem_poll_done(struct scmi_shared_mem __iomem *shmem,
237237
struct scmi_xfer *xfer);

drivers/firmware/arm_scmi/driver.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ static void scmi_handle_notification(struct scmi_chan_info *cinfo, u32 msg_hdr)
213213
if (IS_ERR(xfer)) {
214214
dev_err(dev, "failed to get free message slot (%ld)\n",
215215
PTR_ERR(xfer));
216-
info->desc->ops->clear_notification(cinfo);
216+
info->desc->ops->clear_channel(cinfo);
217217
return;
218218
}
219219

@@ -228,7 +228,7 @@ static void scmi_handle_notification(struct scmi_chan_info *cinfo, u32 msg_hdr)
228228

229229
__scmi_xfer_put(minfo, xfer);
230230

231-
info->desc->ops->clear_notification(cinfo);
231+
info->desc->ops->clear_channel(cinfo);
232232
}
233233

234234
static void scmi_handle_response(struct scmi_chan_info *cinfo,

drivers/firmware/arm_scmi/mailbox.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,11 +166,11 @@ static void mailbox_fetch_notification(struct scmi_chan_info *cinfo,
166166
shmem_fetch_notification(smbox->shmem, max_len, xfer);
167167
}
168168

169-
static void mailbox_clear_notification(struct scmi_chan_info *cinfo)
169+
static void mailbox_clear_channel(struct scmi_chan_info *cinfo)
170170
{
171171
struct scmi_mailbox *smbox = cinfo->transport_info;
172172

173-
shmem_clear_notification(smbox->shmem);
173+
shmem_clear_channel(smbox->shmem);
174174
}
175175

176176
static bool
@@ -189,7 +189,7 @@ static struct scmi_transport_ops scmi_mailbox_ops = {
189189
.mark_txdone = mailbox_mark_txdone,
190190
.fetch_response = mailbox_fetch_response,
191191
.fetch_notification = mailbox_fetch_notification,
192-
.clear_notification = mailbox_clear_notification,
192+
.clear_channel = mailbox_clear_channel,
193193
.poll_done = mailbox_poll_done,
194194
};
195195

drivers/firmware/arm_scmi/shmem.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ void shmem_fetch_notification(struct scmi_shared_mem __iomem *shmem,
7777
memcpy_fromio(xfer->rx.buf, shmem->msg_payload, xfer->rx.len);
7878
}
7979

80-
void shmem_clear_notification(struct scmi_shared_mem __iomem *shmem)
80+
void shmem_clear_channel(struct scmi_shared_mem __iomem *shmem)
8181
{
8282
iowrite32(SCMI_SHMEM_CHAN_STAT_CHANNEL_FREE, &shmem->channel_status);
8383
}

0 commit comments

Comments
 (0)