usb: musb: tweak musb_read_fifo() to avoid unused warnings
Subsystems (2)
PATCH 1/1 usb: musb: tweak musb_read_fifo() to avoid unused warnings
From: Mike Frysinger <[email protected]>
--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)
drivers/usb/musb/blackfin.c +5 -4
@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xu8 epnum = hw_ep->epnum;u16 dma_reg =0 ; -DBG (4 ,"%cX ep%d fifo %p count %d buf %p\n" , -'R' , hw_ep->epnum, fifo, len, dst); - -#ifdef CONFIG_BF52xinvalidate_dcache_range ((unsigned int )dst, (unsigned int )(dst + len));
@@ -103,6 +101,9 @@ void musb_read_fifo(struct musb_hw_ep *hw_ep, u16 len, u8 *dst) len & 0x01 ? (len >> 1) + 1 : len >> 1);#endif +DBG (4 ,"%cX ep%d fifo %p count %d buf %p\n" , +'R' , hw_ep->epnum, fifo, len, dst); +dump_fifo_data (dst, len); }
Signature · 1 line
1.5.6.3
Quoted 1 line · Bryan Wu
From: Mike Frysinger <[email protected]>
I'd like to get a patch body here.
Quoted 11 lines
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)drivers/usb/musb/blackfin.c +0
-0
drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 60
Quoted 7 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xu8 epnum = hw_ep->epnum;u16 dma_reg =0 ;
Is this patch avoiding a warning about these variables being unused ?
Would be nice to get this info to the patch body ;-)
otherwise, looks fine.
Signature · 1 line
balbi
Quoted 26 lines · Felipe Balbi
Quoted 1 line · Bryan Wu
From: Mike Frysinger <[email protected]>
I'd like to get a patch body here.
Quoted 11 lines
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)drivers/usb/musb/blackfin.c +0
-0drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 60
Quoted 7 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xu8 epnum = hw_ep->epnum;u16 dma_reg =0 ;Is this patch avoiding a warning about these variables being unused ?
Quoted 1 line
Would be nice to get this info to the patch body ;-)
the subject already says that
-mike
Quoted 27 lines · Mike Frysinger
Quoted 26 lines · Felipe Balbi
Quoted 1 line · Bryan Wu
From: Mike Frysinger <[email protected]>
I'd like to get a patch body here.
Quoted 11 lines
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)drivers/usb/musb/blackfin.c +0
-0drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 60
Quoted 7 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xu8 epnum = hw_ep->epnum;u16 dma_reg =0 ;Is this patch avoiding a warning about these variables being unused ?
Quoted 3 lines
Quoted 1 line
Would be nice to get this info to the patch body ;-)
the subject already says that
the subject says:
"tweak musb_read_fifo() to avoid unused warnings"
it doesn't specify where are the warnings.
Signature · 1 line
balbi
Quoted 30 lines · Felipe Balbi
Quoted 29 lines · Mike Frysinger
Quoted 27 lines · Felipe Balbi
Quoted 1 line · Bryan Wu
From: Mike Frysinger <[email protected]>
I'd like to get a patch body here.
Quoted 11 lines
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)drivers/usb/musb/blackfin.c +0
-0drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 60
Quoted 7 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xu8 epnum = hw_ep->epnum;u16 dma_reg =0 ;Is this patch avoiding a warning about these variables being unused ?
Would be nice to get this info to the patch body ;-)
Quoted 7 lines
Quoted 1 line
the subject already says that
the subject says:
"tweak
musb_read_fifo()to avoid unused warnings"it doesn't specify where are the warnings.
i dont think it really adds anything to explicitly mention every variable that triggers an unused warning. but if we look at the code that changed, it's easy to see that it's epnum and dma_reg. -mike
Quoted 11 lines · Mike Frysinger
Quoted 7 lines
Quoted 1 line
the subject already says that
the subject says:
"tweak
musb_read_fifo()to avoid unused warnings"it doesn't specify where are the warnings.
i dont think it really adds anything to explicitly mention every variable that triggers an unused warning. but if we look at the code that changed, it's easy to see that it's epnum and
dma_reg.
Still I like to see patch bodies otherwise git log will look awkward.
Signature · 1 line
balbi
Quoted 13 lines · Bryan Wu
From: Mike Frysinger <[email protected]>
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)drivers/usb/musb/blackfin.c +0
-0
drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 58
Quoted 5 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52x
Any way we can just not have ifdefs in .c files alltogether?
thanks,
greg k-h
Quoted 9 lines · Greg KH
Quoted 8 lines · Bryan Wu
From: Mike Frysinger <[email protected]>
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)
Quoted 12 lines
drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 58
Quoted 10 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xAny way we can just not have ifdefs in .c files alltogether?
the sub arch.c files for musb are pretty much header files. the alternative (splitting up the funcs into their own header files) would be much more bothersome for us to maintain atm i think since there's so very little different.
-mike
Quoted 23 lines · Mike Frysinger
Quoted 9 lines · Greg KH
Quoted 8 lines · Bryan Wu
From: Mike Frysinger <[email protected]>
Signed-off-by Mike Frysinger <[email protected]>Signed-off-by Bryan Wu <[email protected]>--- drivers/usb/musb/blackfin.c | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-)Quoted 12 lines
drivers/usb/musb/blackfin.c void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src) · line 58
Quoted 10 lines
drivers/usb/musb/blackfin.c +2
-0@@ -54,13 +54,11 @@ void musb_write_fifo(struct musb_hw_ep *hw_ep, u16 len, const u8 *src)void musb_read_fifo (struct musb_hw_ep *hw_ep,u16 len,u8 *dst) {void __iomem *fifo = hw_ep->fifo; + +#ifdef CONFIG_BF52xAny way we can just not have ifdefs in .c files alltogether?
Quoted 4 lines
the sub
arch.cfiles for musb are pretty much header files. the alternative (splitting up the funcs into their own header files) would be much more bothersome for us to maintain atm i think since there's so very little different.
Ick. Oh well, any cleanup that people can think of would be good in this area...
thanks,
greg k-h
Quoted 5 lines · Mike Frysinger
Quoted 3 lines
Is this patch avoiding a warning about these variables being unused ?
Would be nice to get this info to the patch body ;-)
the subject already says that
Not enough.
Mike, why is it that patches from ADI generally don't include
patch descriptions? It's not like folk haven't asked for them...
In the case of "avoid a warning" patches, the convention is to have the patch summary include the warnings being avoided. (Or at least a few, if they're too numerous.)