lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ad857b9d-7f8b-cf65-5f1c-5d66b4cf60b9@oracle.com>
Date:   Wed, 8 Feb 2017 13:50:27 -0800
From:   Shannon Nelson <shannon.nelson@...cle.com>
To:     David Miller <davem@...emloft.net>
Cc:     netdev@...r.kernel.org, sparclinux@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 net-next 1/9] sunvnet: make sunvnet common code
 dynamically loadable

On 2/8/2017 11:29 AM, David Miller wrote:
> From: Shannon Nelson <shannon.nelson@...cle.com>
> Date: Tue,  7 Feb 2017 14:12:54 -0800
>
>> +static int __init sunvnet_common_init(void)
>> +{
>> +	pr_info("%s\n", version);
>> +	return 0;
>> +}
>> +module_init(sunvnet_common_init);
>> +
>> +static void __exit sunvnet_common_exit(void)
>> +{
>> +	/* Empty function, just here to fill the exit function pointer
>> +	 * slot.  In some combinations of older gcc and newer kernel,
>> +	 * leaving this undefined results in the kernel marking it as a
>> +	 * permanent module; it will show up in lsmod output as [permanent]
>> +	 * and not be unloadable.
>> +	 */
>> +}
>> +module_exit(sunvnet_common_exit);
>> +
>
> This module is just providing infrastructure for other modules.
>
> So skip the init function, and that way you don't need the exit
> function either.
>
> The kernel log message when the real sunvnet driver loads is
> sufficient, you don't need one here.
>

Sure - thanks,
sln

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ