Subject: Re: [PATCH net-next v2 1/2] ethernet: realtek: use module_pci_driver

From: Varka Bhadram <[email-masked]>
Date: Tue, 22 Jul 2014 13:54:17 +0530

On 07/22/2014 12:58 PM, David Miller wrote:
> From: [email-masked]
> Date: Tue, 22 Jul 2014 12:50:21 +0530
>
>> @@ -1887,11 +1887,7 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
>>   	resource_size_t pciaddr;
>>   	unsigned int addr_len, i, pci_using_dac;
>>   
>> -#ifndef MODULE
>> -	static int version_printed;
>> -	if (version_printed++ == 0)
>> -		pr_info("%s", version);
>> -#endif
>> +	pr_info("%s", version);
> Now you're changing behavior undesirably, it will now print the
> version string into the logs for every instance of the device which is
> discovered.
>
> Seriously, the driver is worse off after these "cleanups".

Here we are having two possibilities here:

1. Removing the version info completely. Ofcourse this is not desirable.
  
2. Accepting the version info to be print into log messages.

I will put like this by removing #ifdefs:
	static int version_printed;
	if (version_printed++ == 0)
		pr_info("%s", version);

Will it be OK ..?

-- 
Regards,
Varka Bhadram.