From c206c70924737db6836382c09ad2dacd04bb6204 Mon Sep 17 00:00:00 2001 From: Philip J Kelleher Date: Mon, 18 Feb 2013 21:35:59 +0100 Subject: block: IBM RamSan 70/80 driver fixes This patch includes the following driver fixes for the IBM RamSan 70/80 driver: o Changed the creg_ctrl lock from a mutex to a spinlock. o Added a count check for ioctl calls. o Removed unnecessary casting of void pointers. o Made every function static that needed to be. o Added comments to explain things more thoroughly. Signed-off-by: Philip J Kelleher Signed-off-by: Jens Axboe --- drivers/block/rsxx/dma.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'drivers/block/rsxx/dma.c') diff --git a/drivers/block/rsxx/dma.c b/drivers/block/rsxx/dma.c index 872f50358624..63176e67662f 100644 --- a/drivers/block/rsxx/dma.c +++ b/drivers/block/rsxx/dma.c @@ -102,7 +102,7 @@ struct dma_tracker_list { /*----------------- Misc Utility Functions -------------------*/ -unsigned int rsxx_addr8_to_laddr(u64 addr8, struct rsxx_cardinfo *card) +static unsigned int rsxx_addr8_to_laddr(u64 addr8, struct rsxx_cardinfo *card) { unsigned long long tgt_addr8; @@ -113,7 +113,7 @@ unsigned int rsxx_addr8_to_laddr(u64 addr8, struct rsxx_cardinfo *card) return tgt_addr8; } -unsigned int rsxx_get_dma_tgt(struct rsxx_cardinfo *card, u64 addr8) +static unsigned int rsxx_get_dma_tgt(struct rsxx_cardinfo *card, u64 addr8) { unsigned int tgt; @@ -757,7 +757,7 @@ static int rsxx_dma_ctrl_init(struct pci_dev *dev, INIT_LIST_HEAD(&ctrl->queue); setup_timer(&ctrl->activity_timer, dma_engine_stalled, - (unsigned long)ctrl); + (unsigned long)ctrl); ctrl->issue_wq = alloc_ordered_workqueue(DRIVER_NAME"_issue", 0); if (!ctrl->issue_wq) @@ -803,7 +803,7 @@ static int rsxx_dma_ctrl_init(struct pci_dev *dev, return 0; } -int rsxx_dma_stripe_setup(struct rsxx_cardinfo *card, +static int rsxx_dma_stripe_setup(struct rsxx_cardinfo *card, unsigned int stripe_size8) { if (!is_power_of_2(stripe_size8)) { @@ -834,7 +834,7 @@ int rsxx_dma_stripe_setup(struct rsxx_cardinfo *card, return 0; } -int rsxx_dma_configure(struct rsxx_cardinfo *card) +static int rsxx_dma_configure(struct rsxx_cardinfo *card) { u32 intr_coal; -- cgit v1.2.1