Skip to content

Commit fb12940

Browse files
committed
driver core: fix up some missing class.devnode() conversions.
In commit ff62b8e ("driver core: make struct class.devnode() take a const *") the ->devnode callback changed the pointer to be const, but a few instances of PowerPC drivers were not caught for some reason. Fix this up by changing the pointers to be const. Fixes: ff62b8e ("driver core: make struct class.devnode() take a const *") Cc: Michael Ellerman <[email protected]> Cc: Nicholas Piggin <[email protected]> Cc: Christophe Leroy <[email protected]> Cc: Frederic Barrat <[email protected]> Cc: Andrew Donnellan <[email protected]> Cc: Arnd Bergmann <[email protected]> Cc: [email protected] Reported-by: Stephen Rothwell <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent ff62b8e commit fb12940

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

arch/powerpc/platforms/book3s/vas-api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ struct coproc_instance {
5353
struct vas_window *txwin;
5454
};
5555

56-
static char *coproc_devnode(struct device *dev, umode_t *mode)
56+
static char *coproc_devnode(const struct device *dev, umode_t *mode)
5757
{
5858
return kasprintf(GFP_KERNEL, "crypto/%s", dev_name(dev));
5959
}

drivers/misc/cxl/file.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -546,7 +546,7 @@ static const struct file_operations afu_master_fops = {
546546
};
547547

548548

549-
static char *cxl_devnode(struct device *dev, umode_t *mode)
549+
static char *cxl_devnode(const struct device *dev, umode_t *mode)
550550
{
551551
if (cpu_has_feature(CPU_FTR_HVMODE) &&
552552
CXL_DEVT_IS_CARD(dev->devt)) {

drivers/misc/ocxl/file.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,7 +581,7 @@ void ocxl_file_unregister_afu(struct ocxl_afu *afu)
581581
device_unregister(&info->dev);
582582
}
583583

584-
static char *ocxl_devnode(struct device *dev, umode_t *mode)
584+
static char *ocxl_devnode(const struct device *dev, umode_t *mode)
585585
{
586586
return kasprintf(GFP_KERNEL, "ocxl/%s", dev_name(dev));
587587
}

0 commit comments

Comments
 (0)