Commit 5852357
cdx: Fix cdx_mmap_resource() after constifying attr in ->mmap()
Commit 94a20fb ("sysfs: treewide: constify attribute callback of
bin_attribute::mmap()") missed updating the attr parameter of
cdx_mmap_resource(), resulting in a build failure.
drivers/cdx/cdx.c: In function 'cdx_create_res_attr':
drivers/cdx/cdx.c:773:24: error: assignment to 'int (*)(struct file *, struct kobject *, const struct bin_attribute *, struct vm_area_struct *)' from incompatible pointer type 'int (*)(struct file *, struct kobject *, struct bin_attribute *, struct vm_area_struct *)' [-Wincompatible-pointer-types]
773 | res_attr->mmap = cdx_mmap_resource;
| ^
Update cdx_mmap_resource() to match, resolving the build failure.
Fixes: 94a20fb ("sysfs: treewide: constify attribute callback of bin_attribute::mmap()")
Signed-off-by: Nathan Chancellor <[email protected]>
Tested-by: Thorsten Leemhuis <[email protected]>
Reviewed-by: Thomas Weißschuu <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>1 parent 298c2af commit 5852357
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
707 | 707 | | |
708 | 708 | | |
709 | 709 | | |
710 | | - | |
| 710 | + | |
711 | 711 | | |
712 | 712 | | |
713 | 713 | | |
| |||
0 commit comments