[linux-yocto] [PATCH v2] ti81xx: Fix buffer overflow error in sysfs pin-mux interface.
Bruce Ashfield
bruce.ashfield at windriver.com
Wed Jul 17 22:22:03 PDT 2013
On 13-07-17 11:08 AM, Graeme Smecher wrote:
> This bug was introduced in commit d00bf72d119d98b2a19b48b2eebdc8b5b657284d.
> The declaration of the "mode" variable didn't reserve enough space for ti816x
> or ti814x strings. The result was corruption when displaying files in
> /sys/kernel/debug/omap_mux.
This looks to be broken in all the mainline kernels that I checked from
3.4 -> 3.11-rc.
Which kernel version in particular did you test it with ? That'll guide
where I apply it.
Are there plans to upstream the change, or is it already staged in a TI
tree, or arm repo ?
Cheers,
Bruce
>
> Signed-off-by: Graeme Smecher <gsmecher at threespeedlogic.com>
> To: Ravikumar Kattekola <rk at ti.com>
> ---
> arch/arm/mach-omap2/mux.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-omap2/mux.c b/arch/arm/mach-omap2/mux.c
> index 87e4dd1..983555d 100644
> --- a/arch/arm/mach-omap2/mux.c
> +++ b/arch/arm/mach-omap2/mux.c
> @@ -445,7 +445,7 @@ static inline void omap_mux_decode(struct seq_file *s, u32 val)
> static inline void ti81xx_mux_decode(struct seq_file *s, u32 val)
> {
> char *flags[OMAP_MUX_MAX_NR_FLAGS];
> - char mode[sizeof("OMAP_MUX_MODE") + 1];
> + char mode[sizeof("TI81XX_MUX_MODE") + 2];
> int i = -1;
>
> if (cpu_is_ti816x()) {
>
More information about the linux-yocto
mailing list