Re: [2/2] watchdog: xen_wdt: remove info message and version number

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 06, 2017 at 05:39:03PM +0000, Radu Rendec wrote:
> On Sun, 2017-11-05 at 07:39 -0800, Guenter Roeck wrote:
> > On Fri, Nov 03, 2017 at 03:31:53PM +0000, Radu Rendec wrote:
> > > The initial info message (early in the xen_wdt_init_module() function)
> > > is not very useful and we already have a message on successful probe. If
> > > the probe fails, additional messages are printed anyway.
> > > 
> > > The version number serves no useful purpose and it ran out of favor
> > > upstream anyway.
> > > 
> > 
> > As I mentioned in the other patch, any chance to use
> > module_platform_driver_probe() ? The
> > 
> > 	if (!xen_domain())
> > 		return -ENODEV;
> > 
> > could be moved there.
> 
> I see your point, but I think module_platform_driver_probe() can't be
> used here. The problem is that there's nothing else to create the
> platform device, so if xen_wdt doesn't create it on its own, there will
> be no (matching) platform device to be probed by the driver that
> xen_wdt registers.
> 
> I looked at module_platform_driver_probe() and it's a convenience macro
> that ultimately calls __platform_driver_probe(). The latter is just
> __platform_driver_register() with some additional tricks around the
> probe function.
> 
> The current version works because platform_device_register_simple()
> (called by the module init function) conveniently allocates and
> registers a matching platform device.
> 
> Looking at platform_device.h, I don't see any other macros that we
> could use instead.
> 
> I already fixed the other issues in the previous patch so, unless you
> think init/exit can be simplified in a different way, I am ready to
> resend the (updated) patches.
> 
Ok; thanks for having a look.

Guenter
--
To unsubscribe from this list: send the line "unsubscribe linux-watchdog" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux