mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH 1/3] globalvar: remove unused globalvar_add()
@ 2017-04-07  6:59 Sascha Hauer
  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
  0 siblings, 2 replies; 3+ messages in thread
From: Sascha Hauer @ 2017-04-07  6:59 UTC (permalink / raw)
  To: Barebox List

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-04-07  6:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-07  6:59 [PATCH 1/3] globalvar: remove unused globalvar_add() Sascha Hauer
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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox