diff options
author | Mike Frysinger <vapier@gentoo.org> | 2010-10-20 11:18:03 (GMT) |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2010-12-09 09:24:09 (GMT) |
commit | 32ff4b7fe410bdea29ca38ab15f57e731fc920d1 (patch) | |
tree | 98c674e5beaa58074359208a393449307b4a54eb | |
parent | 543f0a3819a9af130f3f80a660099fad8d2d4b8e (diff) | |
download | u-boot-fsl-qoriq-32ff4b7fe410bdea29ca38ab15f57e731fc920d1.tar.xz |
stdio: constify "name" arg in public api
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-rw-r--r-- | common/console.c | 4 | ||||
-rw-r--r-- | common/stdio.c | 4 | ||||
-rw-r--r-- | include/common.h | 2 | ||||
-rw-r--r-- | include/iomux.h | 2 | ||||
-rw-r--r-- | include/stdio_dev.h | 4 |
5 files changed, 8 insertions, 8 deletions
diff --git a/common/console.c b/common/console.c index 7e01886..8c650e0 100644 --- a/common/console.c +++ b/common/console.c @@ -479,7 +479,7 @@ inline void dbg(const char *fmt, ...) /** U-Boot INIT FUNCTIONS *************************************************/ -struct stdio_dev *search_device(int flags, char *name) +struct stdio_dev *search_device(int flags, const char *name) { struct stdio_dev *dev; @@ -491,7 +491,7 @@ struct stdio_dev *search_device(int flags, char *name) return NULL; } -int console_assign(int file, char *devname) +int console_assign(int file, const char *devname) { int flag; struct stdio_dev *dev; diff --git a/common/stdio.c b/common/stdio.c index ab7c5ab..b20772c 100644 --- a/common/stdio.c +++ b/common/stdio.c @@ -105,7 +105,7 @@ struct list_head* stdio_get_list(void) return &(devs.list); } -struct stdio_dev* stdio_get_by_name(char* name) +struct stdio_dev* stdio_get_by_name(const char *name) { struct list_head *pos; struct stdio_dev *dev; @@ -155,7 +155,7 @@ int stdio_register (struct stdio_dev * dev) * returns 0 if success, -1 if device is assigned and 1 if devname not found */ #ifdef CONFIG_SYS_STDIO_DEREGISTER -int stdio_deregister(char *devname) +int stdio_deregister(const char *devname) { int l; struct list_head *pos; diff --git a/include/common.h b/include/common.h index 189ad81..0d1c872 100644 --- a/include/common.h +++ b/include/common.h @@ -655,7 +655,7 @@ char * strmhz(char *buf, long hz); /* common/console.c */ int console_init_f(void); /* Before relocation; uses the serial stuff */ int console_init_r(void); /* After relocation; uses the console stuff */ -int console_assign (int file, char *devname); /* Assign the console */ +int console_assign(int file, const char *devname); /* Assign the console */ int ctrlc (void); int had_ctrlc (void); /* have we had a Control-C since last clear? */ void clear_ctrlc (void); /* clear the Control-C condition */ diff --git a/include/iomux.h b/include/iomux.h index e38a81e..fcf0f93 100644 --- a/include/iomux.h +++ b/include/iomux.h @@ -43,6 +43,6 @@ extern int cd_count[MAX_FILES]; int iomux_doenv(const int, const char *); void iomux_printdevs(const int); -struct stdio_dev *search_device(int, char *); +struct stdio_dev *search_device(int, const char *); #endif /* _IO_MUX_H */ diff --git a/include/stdio_dev.h b/include/stdio_dev.h index 83da4cd..82ad463 100644 --- a/include/stdio_dev.h +++ b/include/stdio_dev.h @@ -93,10 +93,10 @@ int stdio_register (struct stdio_dev * dev); int stdio_init (void); void stdio_print_current_devices(void); #ifdef CONFIG_SYS_STDIO_DEREGISTER -int stdio_deregister(char *devname); +int stdio_deregister(const char *devname); #endif struct list_head* stdio_get_list(void); -struct stdio_dev* stdio_get_by_name(char* name); +struct stdio_dev* stdio_get_by_name(const char* name); struct stdio_dev* stdio_clone(struct stdio_dev *dev); #ifdef CONFIG_ARM_DCC_MULTI |