aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafał Miłecki <zajec5@gmail.com>2012-11-12 07:03:20 -0500
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>2012-11-22 02:32:28 -0500
commit8d4b9e3182634d8b5afb5a144a8c6c24b187bcc1 (patch)
tree0b9d29e976b969391372675d13f51804b45260d0
parent60768368b76b2794b088bb66fbd07557a10fa77e (diff)
bcma: export PLL reading function
This is required by NAND flash driver for initializing wait counters. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
-rw-r--r--drivers/bcma/driver_chipcommon_pmu.c3
-rw-r--r--include/linux/bcma/bcma.h1
2 files changed, 3 insertions, 1 deletions
diff --git a/drivers/bcma/driver_chipcommon_pmu.c b/drivers/bcma/driver_chipcommon_pmu.c
index 201faf106b3f..657f23517481 100644
--- a/drivers/bcma/driver_chipcommon_pmu.c
+++ b/drivers/bcma/driver_chipcommon_pmu.c
@@ -13,12 +13,13 @@
13#include <linux/export.h> 13#include <linux/export.h>
14#include <linux/bcma/bcma.h> 14#include <linux/bcma/bcma.h>
15 15
16static u32 bcma_chipco_pll_read(struct bcma_drv_cc *cc, u32 offset) 16u32 bcma_chipco_pll_read(struct bcma_drv_cc *cc, u32 offset)
17{ 17{
18 bcma_cc_write32(cc, BCMA_CC_PLLCTL_ADDR, offset); 18 bcma_cc_write32(cc, BCMA_CC_PLLCTL_ADDR, offset);
19 bcma_cc_read32(cc, BCMA_CC_PLLCTL_ADDR); 19 bcma_cc_read32(cc, BCMA_CC_PLLCTL_ADDR);
20 return bcma_cc_read32(cc, BCMA_CC_PLLCTL_DATA); 20 return bcma_cc_read32(cc, BCMA_CC_PLLCTL_DATA);
21} 21}
22EXPORT_SYMBOL_GPL(bcma_chipco_pll_read);
22 23
23void bcma_chipco_pll_write(struct bcma_drv_cc *cc, u32 offset, u32 value) 24void bcma_chipco_pll_write(struct bcma_drv_cc *cc, u32 offset, u32 value)
24{ 25{
diff --git a/include/linux/bcma/bcma.h b/include/linux/bcma/bcma.h
index 4180eb78d575..4fb6bd7941d7 100644
--- a/include/linux/bcma/bcma.h
+++ b/include/linux/bcma/bcma.h
@@ -345,6 +345,7 @@ extern void bcma_core_set_clockmode(struct bcma_device *core,
345 enum bcma_clkmode clkmode); 345 enum bcma_clkmode clkmode);
346extern void bcma_core_pll_ctl(struct bcma_device *core, u32 req, u32 status, 346extern void bcma_core_pll_ctl(struct bcma_device *core, u32 req, u32 status,
347 bool on); 347 bool on);
348extern u32 bcma_chipco_pll_read(struct bcma_drv_cc *cc, u32 offset);
348#define BCMA_DMA_TRANSLATION_MASK 0xC0000000 349#define BCMA_DMA_TRANSLATION_MASK 0xC0000000
349#define BCMA_DMA_TRANSLATION_NONE 0x00000000 350#define BCMA_DMA_TRANSLATION_NONE 0x00000000
350#define BCMA_DMA_TRANSLATION_DMA32_CMT 0x40000000 /* Client Mode Translation for 32-bit DMA */ 351#define BCMA_DMA_TRANSLATION_DMA32_CMT 0x40000000 /* Client Mode Translation for 32-bit DMA */