projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ebbd97a
)
drm: refactor call to request_module
author
Kees Cook
<keescook@chromium.org>
Tue, 7 May 2013 19:32:16 +0000
(12:32 -0700)
committer
Dave Airlie
<airlied@redhat.com>
Fri, 10 May 2013 04:46:03 +0000
(14:46 +1000)
This reduces the size of the stack frame when calling request_module().
Performing the sprintf before the call is not needed.
Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/drm_encoder_slave.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/gpu/drm/drm_encoder_slave.c
b/drivers/gpu/drm/drm_encoder_slave.c
index 48c52f7df4e63affac527e1f86e06188a03e2021..0cfb60f5476655edc097ca71c648d11544f3357e 100644
(file)
--- a/
drivers/gpu/drm/drm_encoder_slave.c
+++ b/
drivers/gpu/drm/drm_encoder_slave.c
@@
-54,16
+54,12
@@
int drm_i2c_encoder_init(struct drm_device *dev,
struct i2c_adapter *adap,
const struct i2c_board_info *info)
{
- char modalias[sizeof(I2C_MODULE_PREFIX)
- + I2C_NAME_SIZE];
struct module *module = NULL;
struct i2c_client *client;
struct drm_i2c_encoder_driver *encoder_drv;
int err = 0;
- snprintf(modalias, sizeof(modalias),
- "%s%s", I2C_MODULE_PREFIX, info->type);
- request_module(modalias);
+ request_module("%s%s", I2C_MODULE_PREFIX, info->type);
client = i2c_new_device(adap, info);
if (!client) {