diff options
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/ati_radeon_fb.c | 3 | ||||
-rw-r--r-- | drivers/video/cfb_console.c | 2 | ||||
-rw-r--r-- | drivers/video/mb862xx.c | 3 | ||||
-rw-r--r-- | drivers/video/mx3fb.c | 2 | ||||
-rw-r--r-- | drivers/video/mxsfb.c | 2 | ||||
-rw-r--r-- | drivers/video/videomodes.c | 5 |
6 files changed, 10 insertions, 7 deletions
diff --git a/drivers/video/ati_radeon_fb.c b/drivers/video/ati_radeon_fb.c index 07a29eaba1..5b6c42291c 100644 --- a/drivers/video/ati_radeon_fb.c +++ b/drivers/video/ati_radeon_fb.c @@ -637,7 +637,8 @@ void *video_hw_init(void) videomode = CONFIG_SYS_DEFAULT_VIDEO_MODE; /* get video mode via environment */ - if ((penv = getenv ("videomode")) != NULL) { + penv = env_get("videomode"); + if (penv) { /* deceide if it is a string */ if (penv[0] <= '9') { videomode = (int) simple_strtoul (penv, NULL, 16); diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index b6fc7e145b..6c5425c195 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -1856,7 +1856,7 @@ static void *video_logo(void) splash_get_pos(&video_logo_xpos, &video_logo_ypos); #ifdef CONFIG_SPLASH_SCREEN - s = getenv("splashimage"); + s = env_get("splashimage"); if (s != NULL) { ret = splash_screen_prepare(); if (ret < 0) diff --git a/drivers/video/mb862xx.c b/drivers/video/mb862xx.c index 1c74e97c5e..e0565e1d2e 100644 --- a/drivers/video/mb862xx.c +++ b/drivers/video/mb862xx.c @@ -246,7 +246,8 @@ unsigned int card_init (void) tmp = 0; videomode = 0x310; /* get video mode via environment */ - if ((penv = getenv ("videomode")) != NULL) { + penv = env_get("videomode"); + if (penv) { /* decide if it is a string */ if (penv[0] <= '9') { videomode = (int) simple_strtoul (penv, NULL, 16); diff --git a/drivers/video/mx3fb.c b/drivers/video/mx3fb.c index 51d06d6677..78e595ea4a 100644 --- a/drivers/video/mx3fb.c +++ b/drivers/video/mx3fb.c @@ -816,7 +816,7 @@ void *video_hw_init(void) videomode = CONFIG_SYS_DEFAULT_VIDEO_MODE; /* get video mode via environment */ - penv = getenv("videomode"); + penv = env_get("videomode"); if (penv) { /* decide if it is a string */ if (penv[0] <= '9') { diff --git a/drivers/video/mxsfb.c b/drivers/video/mxsfb.c index 0ddce3db58..9d810bab31 100644 --- a/drivers/video/mxsfb.c +++ b/drivers/video/mxsfb.c @@ -161,7 +161,7 @@ void *video_hw_init(void) puts("Video: "); /* Suck display configuration from "videomode" variable */ - penv = getenv("videomode"); + penv = env_get("videomode"); if (!penv) { puts("MXSFB: 'videomode' variable not set!\n"); return NULL; diff --git a/drivers/video/videomodes.c b/drivers/video/videomodes.c index cf71ad120e..6d96b33f20 100644 --- a/drivers/video/videomodes.c +++ b/drivers/video/videomodes.c @@ -165,7 +165,8 @@ int video_get_params (struct ctfb_res_modes *pPar, char *penv) /* first search for the environment containing the real param string */ s = penv; - if ((p = getenv (s)) != NULL) + p = env_get(s); + if (p) s = p; /* @@ -234,7 +235,7 @@ int video_get_params (struct ctfb_res_modes *pPar, char *penv) int video_get_video_mode(unsigned int *xres, unsigned int *yres, unsigned int *depth, unsigned int *freq, const char **options) { - char *p = getenv("video-mode"); + char *p = env_get("video-mode"); if (!p) return 0; |