[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3685403.qLrNHfR1Kx@wuerfel>
Date: Tue, 02 Sep 2014 19:40:45 +0200
From: Arnd Bergmann <arnd@...db.de>
To: linux-arm-kernel@...ts.infradead.org,
Alexander Shiyan <shc_work@...l.ru>
Cc: kgene.kim@...sung.com, linux@....linux.org.uk, naushad@...sung.com,
lee.jones@...aro.org, Tomasz Figa <t.figa@...sung.com>,
linux-kernel@...r.kernel.org, joshi@...sung.com,
linux-samsung-soc@...r.kernel.org, thomas.ab@...sung.com,
Pankaj Dubey <pankaj.dubey@...sung.com>,
vikas.sajjan@...sung.com, chow.kim@...sung.com,
tomasz.figa@...il.com, Michal Simek <michal.simek@...inx.com>
Subject: Re: [PATCH v2] mfd: syscon: Decouple syscon interface from platform devices
On Tuesday 02 September 2014 19:42:52 Alexander Shiyan wrote:
> > > -struct regmap *syscon_regmap_lookup_by_pdevname(const char *s)
> > > -{
> > > - struct device *dev;
> > > - struct syscon *syscon;
> > > -
> > > - dev = driver_find_device(&syscon_driver.driver, NULL, (void *)s,
> > > - syscon_match_pdevname);
> > > - if (!dev)
> > > - return ERR_PTR(-EPROBE_DEFER);
> > > -
> > > - syscon = dev_get_drvdata(dev);
> > > -
> > > - return syscon->regmap;
> > > -}
> > > -EXPORT_SYMBOL_GPL(syscon_regmap_lookup_by_pdevname);
> >
> > I think this can actually be left intact if that helps with clps71xx.
> > It could be done in a hacky way using bus_find_device_by_name()
> > to keep it simple, or in a somewhat nicer way by keeping the
> > syscon platform_driver around for the non-DT case.
>
> It will not work anyway because the patch involves the use of
> of_device_is_compatible(), of_iomap() etc...
What I meant was to have the pdevname stuff keep working the way
it does today. At that point, you essentially have two completely
independent drivers, one that registers a platform driver and
provides syscon_regmap_lookup_by_pdevname, and one that provides
the other interfaces using DT lookup.
Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists