mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 1/3] globalvar: remove unused globalvar_add()
Date: Fri,  7 Apr 2017 08:59:24 +0200	[thread overview]
Message-ID: <20170407065926.27245-1-s.hauer@pengutronix.de> (raw)

globalvar_add() is unused in the tree. Remove it.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 common/globalvar.c  | 16 ----------------
 include/globalvar.h | 12 ------------
 2 files changed, 28 deletions(-)

diff --git a/common/globalvar.c b/common/globalvar.c
index 4cf635c0c7..971c21949f 100644
--- a/common/globalvar.c
+++ b/common/globalvar.c
@@ -29,22 +29,6 @@ void nv_var_set_clean(void)
 	nv_dirty = 0;
 }
 
-int globalvar_add(const char *name,
-		int (*set)(struct device_d *dev, struct param_d *p, const char *val),
-		const char *(*get)(struct device_d *, struct param_d *p),
-		unsigned long flags)
-{
-	struct param_d *param;
-
-	if (!strncmp(name, "global.", 7))
-		name += 7;
-
-	param = dev_add_param(&global_device, name, set, get, flags);
-	if (IS_ERR(param))
-		return PTR_ERR(param);
-	return 0;
-}
-
 void globalvar_remove(const char *name)
 {
 	struct param_d *p, *tmp;
diff --git a/include/globalvar.h b/include/globalvar.h
index 80bc53e680..df43f1fe66 100644
--- a/include/globalvar.h
+++ b/include/globalvar.h
@@ -11,10 +11,6 @@ extern struct device_d global_device;
 #ifdef CONFIG_GLOBALVAR
 int globalvar_add_simple(const char *name, const char *value);
 
-int globalvar_add(const char *name,
-		int (*set)(struct device_d *dev, struct param_d *p, const char *val),
-		const char *(*get)(struct device_d *, struct param_d *p),
-		unsigned long flags);
 void globalvar_remove(const char *name);
 char *globalvar_get_match(const char *match, const char *separator);
 void globalvar_set_match(const char *match, const char *val);
@@ -80,14 +76,6 @@ static inline int globalvar_add_simple_ip(const char *name,
 	return 0;
 }
 
-static inline int globalvar_add(const char *name,
-		int (*set)(struct device_d *dev, struct param_d *p, const char *val),
-		const char *(*get)(struct device_d *, struct param_d *p),
-		unsigned long flags)
-{
-	return 0;
-}
-
 static inline void globalvar_remove(const char *name) {}
 
 static inline void globalvar_print(void) {}
-- 
2.11.0


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

             reply	other threads:[~2017-04-07  6:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-07  6:59 Sascha Hauer [this message]
2017-04-07  6:59 ` [PATCH 2/3] nv: Do not create globalvars from nvvars Sascha Hauer
2017-04-07  6:59 ` [PATCH 3/3] globalvar: remove code for unqualified globalvars Sascha Hauer

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=20170407065926.27245-1-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.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