Re: [PATCH 3/4] eeepc-wmi: use a platform device as parent device of all sub-devices

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

 



Hi Yong,

On Fri, Apr 09, 2010 at 11:06:52PM +0800, Yong Wang wrote:
> +
> +static void eeepc_wmi_input_exit(struct eeepc_wmi *eeepc_wmi)
> +{
> +	if (eeepc_wmi->input_dev) {

You abandon platform probe if input initialization fails, therefore you
do not need to check for presence of input device on removal, right?

>  
> -	wmi_set_driver_data(EEEPC_WMI_EVENT_GUID, eeepc_wmi);
>  
> -	err = eeepc_wmi_input_init(eeepc_wmi);
> +	eeepc_wmi->platform_dev = platform_device_alloc("eeepc-wmi", -1);
> +	if (!eeepc_wmi->platform_dev) {

See if platform_create_bundle() will simplify things for you.

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

[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux