Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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/20200420152315.21008-2-cristian.marussi@arm.com
Signed-off-by: Cristian Marussi <cristian.marussi@arm.com>
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>

authored by

Cristian Marussi and committed by
Sudeep Holla
87dff4e6 4d09852b

+9 -9
+3 -3
drivers/firmware/arm_scmi/common.h
··· 179 179 * @mark_txdone: Callback to mark tx as done 180 180 * @fetch_response: Callback to fetch response 181 181 * @fetch_notification: Callback to fetch notification 182 - * @clear_notification: Callback to clear a pending notification 182 + * @clear_channel: Callback to clear a channel 183 183 * @poll_done: Callback to poll transfer status 184 184 */ 185 185 struct scmi_transport_ops { ··· 194 194 struct scmi_xfer *xfer); 195 195 void (*fetch_notification)(struct scmi_chan_info *cinfo, 196 196 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); 198 198 bool (*poll_done)(struct scmi_chan_info *cinfo, struct scmi_xfer *xfer); 199 199 }; 200 200 ··· 232 232 struct scmi_xfer *xfer); 233 233 void shmem_fetch_notification(struct scmi_shared_mem __iomem *shmem, 234 234 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); 236 236 bool shmem_poll_done(struct scmi_shared_mem __iomem *shmem, 237 237 struct scmi_xfer *xfer);
+2 -2
drivers/firmware/arm_scmi/driver.c
··· 213 213 if (IS_ERR(xfer)) { 214 214 dev_err(dev, "failed to get free message slot (%ld)\n", 215 215 PTR_ERR(xfer)); 216 - info->desc->ops->clear_notification(cinfo); 216 + info->desc->ops->clear_channel(cinfo); 217 217 return; 218 218 } 219 219 ··· 228 228 229 229 __scmi_xfer_put(minfo, xfer); 230 230 231 - info->desc->ops->clear_notification(cinfo); 231 + info->desc->ops->clear_channel(cinfo); 232 232 } 233 233 234 234 static void scmi_handle_response(struct scmi_chan_info *cinfo,
+3 -3
drivers/firmware/arm_scmi/mailbox.c
··· 166 166 shmem_fetch_notification(smbox->shmem, max_len, xfer); 167 167 } 168 168 169 - static void mailbox_clear_notification(struct scmi_chan_info *cinfo) 169 + static void mailbox_clear_channel(struct scmi_chan_info *cinfo) 170 170 { 171 171 struct scmi_mailbox *smbox = cinfo->transport_info; 172 172 173 - shmem_clear_notification(smbox->shmem); 173 + shmem_clear_channel(smbox->shmem); 174 174 } 175 175 176 176 static bool ··· 189 189 .mark_txdone = mailbox_mark_txdone, 190 190 .fetch_response = mailbox_fetch_response, 191 191 .fetch_notification = mailbox_fetch_notification, 192 - .clear_notification = mailbox_clear_notification, 192 + .clear_channel = mailbox_clear_channel, 193 193 .poll_done = mailbox_poll_done, 194 194 }; 195 195
+1 -1
drivers/firmware/arm_scmi/shmem.c
··· 77 77 memcpy_fromio(xfer->rx.buf, shmem->msg_payload, xfer->rx.len); 78 78 } 79 79 80 - void shmem_clear_notification(struct scmi_shared_mem __iomem *shmem) 80 + void shmem_clear_channel(struct scmi_shared_mem __iomem *shmem) 81 81 { 82 82 iowrite32(SCMI_SHMEM_CHAN_STAT_CHANNEL_FREE, &shmem->channel_status); 83 83 }