From: Daniel Axtens <hidden> Date: 2015-08-07 03:20:53
It's a good idea, and it brings us in line with the rest of arch/powerpc.
Signed-off-by: Daniel Axtens <redacted>
---
drivers/misc/cxl/Makefile | 2 ++
1 file changed, 2 insertions(+)
From: Daniel Axtens <hidden> Date: 2015-08-07 03:20:56
A few declarations were identified by sparse as needing to be static:
/scratch/dja/linux-capi/drivers/misc/cxl/irq.c:408:6: warning: symbol 'afu_irq_name_free' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/irq.c:467:6: warning: symbol 'afu_register_hwirqs' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/file.c:254:6: warning: symbol 'afu_compat_ioctl' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/file.c:399:30: warning: symbol 'afu_master_fops' was not declared. Should it be static?
Make them static.
Signed-off-by: Daniel Axtens <redacted>
---
drivers/misc/cxl/file.c | 4 ++--
drivers/misc/cxl/irq.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
@@ -251,7 +251,7 @@ long afu_ioctl(struct file *file, unsigned int cmd, unsigned long arg)return-EINVAL;}-longafu_compat_ioctl(structfile*file,unsignedintcmd,+staticlongafu_compat_ioctl(structfile*file,unsignedintcmd,unsignedlongarg){returnafu_ioctl(file,cmd,arg);
From: Daniel Axtens <hidden> Date: 2015-08-07 03:21:02
An IO address, tagged with __iomem, is passed to debugfs_create_file
as private data. This requires that it be cast to void *. The cast
creates a sparse warning:
/scratch/dja/linux-capi/drivers/misc/cxl/debugfs.c:51:57: warning: cast removes address space of expression
The address space marker is added back in the file operations
(fops_io_u64).
Silence the warning with __force.
Signed-off-by: Daniel Axtens <redacted>
---
drivers/misc/cxl/debugfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
From: Michael Neuling <hidden> Date: 2015-08-07 04:13:13
On Fri, 2015-08-07 at 13:18 +1000, Daniel Axtens wrote:
An IO address, tagged with __iomem, is passed to debugfs_create_file
as private data. This requires that it be cast to void *. The cast
creates a sparse warning:
/scratch/dja/linux-capi/drivers/misc/cxl/debugfs.c:51:57: warning: cast r=
emoves address space of expression
=20
The address space marker is added back in the file operations
(fops_io_u64).
=20
Silence the warning with __force.
=20
Signed-off-by: Daniel Axtens <redacted>
From: Michael Ellerman <mpe@ellerman.id.au> Date: 2015-08-12 03:19:56
On Fri, 2015-07-08 at 03:18:19 UTC, Daniel Axtens wrote:
Sparse identifies the following address space issues:
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:125:17: warning: incorrect type in assignment (different address spaces)
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:125:17: expected void volatile [noderef] <asn:2>*<noident>
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:125:17: got void *<noident>
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:220:23: warning: incorrect type in assignment (different address spaces)
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:220:23: expected void [noderef] <asn:2>*cfg_data
/scratch/dja/linux-capi/drivers/misc/cxl/vphb.c:220:23: got void *<noident>
Please trim these to just the sub-path under linux, and a two space indent is nice:
drivers/misc/cxl/vphb.c:220:23: got void *<noident>
quoted hunk
Fix those by flagging __iomem in the relevant casts.
Signed-off-by: Daniel Axtens <redacted>
Acked-by: Michael Neuling <redacted>
---
drivers/misc/cxl/vphb.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
From: Michael Ellerman <mpe@ellerman.id.au> Date: 2015-08-13 01:44:24
On Fri, 2015-07-08 at 03:18:18 UTC, Daniel Axtens wrote:
A few declarations were identified by sparse as needing to be static:
/scratch/dja/linux-capi/drivers/misc/cxl/irq.c:408:6: warning: symbol 'afu_irq_name_free' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/irq.c:467:6: warning: symbol 'afu_register_hwirqs' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/file.c:254:6: warning: symbol 'afu_compat_ioctl' was not declared. Should it be static?
/scratch/dja/linux-capi/drivers/misc/cxl/file.c:399:30: warning: symbol 'afu_master_fops' was not declared. Should it be static?
Make them static.
Signed-off-by: Daniel Axtens <redacted>
Acked-by: Michael Neuling <redacted>
From: Michael Ellerman <mpe@ellerman.id.au> Date: 2015-08-13 01:44:25
On Fri, 2015-07-08 at 03:18:20 UTC, Daniel Axtens wrote:
An IO address, tagged with __iomem, is passed to debugfs_create_file
as private data. This requires that it be cast to void *. The cast
creates a sparse warning:
/scratch/dja/linux-capi/drivers/misc/cxl/debugfs.c:51:57: warning: cast removes address space of expression
The address space marker is added back in the file operations
(fops_io_u64).
Silence the warning with __force.
Signed-off-by: Daniel Axtens <redacted>
Acked-by: Michael Neuling <redacted>