Skip to content

Commit

Permalink
can: peak_usb: pcan_dump_mem(): mark input prompt and data pointer as…
Browse files Browse the repository at this point in the history
… const

Mark the input prompt and data pointer as const.

Link: https://lore.kernel.org/all/20220719120632.26774-1-s.grosjean@peak-system.com
Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com>
[mkl: mark data pointer as const, too; update commit message]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
  • Loading branch information
Stephane Grosjean authored and Marc Kleine-Budde committed Jul 19, 2022
1 parent 9e7c9b8 commit 92505df
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion drivers/net/can/usb/peak_usb/pcan_usb_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ MODULE_DEVICE_TABLE(usb, peak_usb_table);
* dump memory
*/
#define DUMP_WIDTH 16
void pcan_dump_mem(char *prompt, void *p, int l)
void pcan_dump_mem(const char *prompt, const void *p, int l)
{
pr_info("%s dumping %s (%d bytes):\n",
PCAN_USB_DRIVER_NAME, prompt ? prompt : "memory", l);
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/can/usb/peak_usb/pcan_usb_core.h
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ struct peak_usb_device {
struct peak_usb_device *next_siblings;
};

void pcan_dump_mem(char *prompt, void *p, int l);
void pcan_dump_mem(const char *prompt, const void *p, int l);

/* common timestamp management */
void peak_usb_init_time_ref(struct peak_time_ref *time_ref,
Expand Down

0 comments on commit 92505df

Please sign in to comment.