Skip to content

Commit c862aab

Browse files
author
Russell King
committed
ARM: amba: make internal ID table handling const
As all probe() functions now take a const pointer, we can make the bus level code deal with const pointers too. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
1 parent aa25afa commit c862aab

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎drivers/amba/bus.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
#define to_amba_device(d) container_of(d, struct amba_device, dev)
2222
#define to_amba_driver(d) container_of(d, struct amba_driver, drv)
2323

24-
static struct amba_id *
25-
amba_lookup(struct amba_id *table, struct amba_device *dev)
24+
static const struct amba_id *
25+
amba_lookup(const struct amba_id *table, struct amba_device *dev)
2626
{
2727
int ret = 0;
2828

@@ -188,7 +188,7 @@ static int amba_probe(struct device *dev)
188188
{
189189
struct amba_device *pcdev = to_amba_device(dev);
190190
struct amba_driver *pcdrv = to_amba_driver(dev->driver);
191-
struct amba_id *id = amba_lookup(pcdrv->id_table, pcdev);
191+
const struct amba_id *id = amba_lookup(pcdrv->id_table, pcdev);
192192
int ret;
193193

194194
do {

0 commit comments

Comments
 (0)