Commit 5ef98192 authored by Thierry Reding's avatar Thierry Reding Committed by Linus Torvalds

memstick: r592: fix build warnings for !PM_SLEEP

When PM_SLEEP is not enabled, the r592_clear_interrupts() function is
never used.  If so, don't build it to prevent a compiler warning.
Signed-off-by: default avatarThierry Reding <treding@nvidia.com>
Cc: Maxim Levitsky <maximlevitsky@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent c70b17b6
...@@ -188,6 +188,7 @@ static void r592_host_reset(struct r592_device *dev) ...@@ -188,6 +188,7 @@ static void r592_host_reset(struct r592_device *dev)
r592_set_mode(dev, dev->parallel_mode); r592_set_mode(dev, dev->parallel_mode);
} }
#ifdef CONFIG_PM_SLEEP
/* Disable all hardware interrupts */ /* Disable all hardware interrupts */
static void r592_clear_interrupts(struct r592_device *dev) static void r592_clear_interrupts(struct r592_device *dev)
{ {
...@@ -195,6 +196,7 @@ static void r592_clear_interrupts(struct r592_device *dev) ...@@ -195,6 +196,7 @@ static void r592_clear_interrupts(struct r592_device *dev)
r592_clear_reg_mask(dev, R592_REG_MSC, IRQ_ALL_ACK_MASK); r592_clear_reg_mask(dev, R592_REG_MSC, IRQ_ALL_ACK_MASK);
r592_clear_reg_mask(dev, R592_REG_MSC, IRQ_ALL_EN_MASK); r592_clear_reg_mask(dev, R592_REG_MSC, IRQ_ALL_EN_MASK);
} }
#endif
/* Tests if there is an CRC error */ /* Tests if there is an CRC error */
static int r592_test_io_error(struct r592_device *dev) static int r592_test_io_error(struct r592_device *dev)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment