Gianfar ethernet device

Jon Smirl jonsmirl at gmail.com
Mon Nov 12 11:30:55 EST 2007


BTW, this exercise of disabling platform bus is turning up some real bugs.

There are several tests in the kernel like this:

        if (!shost->shost_gendev.parent)
                shost->shost_gendev.parent = dev ? dev : &platform_bus;

	if (adap->dev.parent == NULL) {
		adap->dev.parent = &platform_bus;
		pr_debug("I2C adapter driver [%s] forgot to specify "
			 "physical device\n", adap->name);
	}

This doesn't do the right thing when the device is on of_platform_bus
instead of platform_bus. What's the right fix for these? Shouldn't the
call error out instead of trying to fix up the parent? Then fix the
code to set the parent right when the device was created.

-- 
Jon Smirl
jonsmirl at gmail.com



More information about the Linuxppc-dev mailing list