mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Pravin Shedge <pravin.shedge4linux@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: pravin.shedge4linux@gmail.com
Subject: [PATCH 3/3] lib: cleanup dead code from lib/percpu_test.c
Date: Sun, 17 Dec 2017 16:41:37 +0530	[thread overview]
Message-ID: <1513509097-6697-1-git-send-email-pravin.shedge4linux@gmail.com> (raw)

lib/percpu_test.c code allows to compile either as a loadable modules or
builtin into the kernel.

Current code returns -EAGAIN on successful termination from module_init.
Such a fail will directly unload the module and hence there is no scope
to execute percpu_test_exit on module_exit.

Signed-off-by: Pravin Shedge <pravin.shedge4linux@gmail.com>
---
 lib/percpu_test.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/lib/percpu_test.c b/lib/percpu_test.c
index 0b5d14d..ea31adb 100644
--- a/lib/percpu_test.c
+++ b/lib/percpu_test.c
@@ -126,12 +126,7 @@ static int __init percpu_test_init(void)
 	return -EAGAIN;  /* Fail will directly unload the module */
 }
 
-static void __exit percpu_test_exit(void)
-{
-}
-
 module_init(percpu_test_init)
-module_exit(percpu_test_exit)
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Greg Thelen");
-- 
2.7.4

                 reply	other threads:[~2017-12-17 11:12 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1513509097-6697-1-git-send-email-pravin.shedge4linux@gmail.com \
    --to=pravin.shedge4linux@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®