When compiling a 2.6.30 or 2.6.30.1 kernel with the

scst_exec_req_fifo-2.6.30.patch applied, the following warning is printed
many times by the compiler:

include/linux/scatterlist.h:223: warning: ‘enum km_type’ declared
inside parameter list
include/linux/scatterlist.h:223: warning: its scope is only this
definition or declaration, which is probably not what you want
include/linux/scatterlist.h:226: warning: ‘enum km_type’ declared
inside parameter list

The patch below fixes these compiler warnings by adding a forward declaration
for "enum km_type" in include/linux/scatterlist.h.

Signed-off-by: Bart Van Assche <bart.vanassche@gmail.com>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@963 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Vladislav Bolkhovitin
2009-07-20 09:47:36 +00:00
parent 803e706181
commit e609d55773

View File

@@ -640,10 +640,12 @@ diff -upkr linux-2.6.30.1/include/linux/blkdev.h linux-2.6.30.1/include/linux/bl
diff -upkr linux-2.6.30.1/include/linux/scatterlist.h linux-2.6.30.1/include/linux/scatterlist.h
--- linux-2.6.30.1/include/linux/scatterlist.h 2009-06-10 07:05:27.000000000 +0400
+++ linux-2.6.30.1/include/linux/scatterlist.h 2009-07-13 13:56:24.000000000 +0400
@@ -218,6 +218,13 @@ size_t sg_copy_from_buffer(struct scatte
@@ -218,6 +218,15 @@ size_t sg_copy_from_buffer(struct scatte
size_t sg_copy_to_buffer(struct scatterlist *sgl, unsigned int nents,
void *buf, size_t buflen);
+enum km_type;
+
+int sg_copy_elem(struct scatterlist *dst_sg, struct scatterlist *src_sg,
+ size_t copy_len, enum km_type d_km_type,
+ enum km_type s_km_type);