1 From 0fc9d696e4855f1e03910c431499d68e75904929 Mon Sep 17 00:00:00 2001
2 From: Hauke Mehrtens <hauke@hauke-m.de>
3 Date: Sun, 10 Nov 2013 20:43:46 +0100
4 Subject: [PATCH] bcma: export bcma_find_core_unit()
7 drivers/bcma/bcma_private.h | 2 --
8 drivers/bcma/main.c | 13 +------------
9 include/linux/bcma/bcma.h | 9 ++++++++-
10 3 files changed, 9 insertions(+), 15 deletions(-)
12 --- a/drivers/bcma/bcma_private.h
13 +++ b/drivers/bcma/bcma_private.h
14 @@ -33,8 +33,6 @@ int __init bcma_bus_early_register(struc
15 int bcma_bus_suspend(struct bcma_bus *bus);
16 int bcma_bus_resume(struct bcma_bus *bus);
18 -struct bcma_device *bcma_find_core_unit(struct bcma_bus *bus, u16 coreid,
22 int bcma_bus_scan(struct bcma_bus *bus);
23 --- a/drivers/bcma/main.c
24 +++ b/drivers/bcma/main.c
25 @@ -78,18 +78,6 @@ static u16 bcma_cc_core_id(struct bcma_b
26 return BCMA_CORE_CHIPCOMMON;
29 -struct bcma_device *bcma_find_core(struct bcma_bus *bus, u16 coreid)
31 - struct bcma_device *core;
33 - list_for_each_entry(core, &bus->cores, list) {
34 - if (core->id.id == coreid)
39 -EXPORT_SYMBOL_GPL(bcma_find_core);
41 struct bcma_device *bcma_find_core_unit(struct bcma_bus *bus, u16 coreid,
44 @@ -101,6 +89,7 @@ struct bcma_device *bcma_find_core_unit(
48 +EXPORT_SYMBOL_GPL(bcma_find_core_unit);
50 bool bcma_wait_value(struct bcma_device *core, u16 reg, u32 mask, u32 value,
52 --- a/include/linux/bcma/bcma.h
53 +++ b/include/linux/bcma/bcma.h
54 @@ -418,7 +418,14 @@ static inline void bcma_maskset16(struct
55 bcma_write16(cc, offset, (bcma_read16(cc, offset) & mask) | set);
58 -extern struct bcma_device *bcma_find_core(struct bcma_bus *bus, u16 coreid);
59 +extern struct bcma_device *bcma_find_core_unit(struct bcma_bus *bus, u16 coreid,
61 +static inline struct bcma_device *bcma_find_core(struct bcma_bus *bus,
64 + return bcma_find_core_unit(bus, coreid, 0);
67 extern bool bcma_core_is_enabled(struct bcma_device *core);
68 extern void bcma_core_disable(struct bcma_device *core, u32 flags);
69 extern int bcma_core_enable(struct bcma_device *core, u32 flags);