Loading Documentation/networking/cxacru.txt +1 −0 Original line number Original line Diff line number Diff line Loading @@ -61,6 +61,7 @@ several sysfs attribute files for retrieving device statistics: * mac_address * mac_address * modulation * modulation "" (when not connected) "ANSI T1.413" "ANSI T1.413" "ITU-T G.992.1 (G.DMT)" "ITU-T G.992.1 (G.DMT)" "ITU-T G.992.2 (G.LITE)" "ITU-T G.992.2 (G.LITE)" Loading drivers/usb/atm/cxacru.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -267,12 +267,12 @@ static ssize_t cxacru_sysfs_showattr_LINE(u32 value, char *buf) static ssize_t cxacru_sysfs_showattr_MODU(u32 value, char *buf) static ssize_t cxacru_sysfs_showattr_MODU(u32 value, char *buf) { { static char *str[] = { static char *str[] = { NULL, "", "ANSI T1.413", "ANSI T1.413", "ITU-T G.992.1 (G.DMT)", "ITU-T G.992.1 (G.DMT)", "ITU-T G.992.2 (G.LITE)" "ITU-T G.992.2 (G.LITE)" }; }; if (unlikely(value >= ARRAY_SIZE(str) || str[value] == NULL)) if (unlikely(value >= ARRAY_SIZE(str))) return snprintf(buf, PAGE_SIZE, "%u\n", value); return snprintf(buf, PAGE_SIZE, "%u\n", value); return snprintf(buf, PAGE_SIZE, "%s\n", str[value]); return snprintf(buf, PAGE_SIZE, "%s\n", str[value]); } } Loading Loading
Documentation/networking/cxacru.txt +1 −0 Original line number Original line Diff line number Diff line Loading @@ -61,6 +61,7 @@ several sysfs attribute files for retrieving device statistics: * mac_address * mac_address * modulation * modulation "" (when not connected) "ANSI T1.413" "ANSI T1.413" "ITU-T G.992.1 (G.DMT)" "ITU-T G.992.1 (G.DMT)" "ITU-T G.992.2 (G.LITE)" "ITU-T G.992.2 (G.LITE)" Loading
drivers/usb/atm/cxacru.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -267,12 +267,12 @@ static ssize_t cxacru_sysfs_showattr_LINE(u32 value, char *buf) static ssize_t cxacru_sysfs_showattr_MODU(u32 value, char *buf) static ssize_t cxacru_sysfs_showattr_MODU(u32 value, char *buf) { { static char *str[] = { static char *str[] = { NULL, "", "ANSI T1.413", "ANSI T1.413", "ITU-T G.992.1 (G.DMT)", "ITU-T G.992.1 (G.DMT)", "ITU-T G.992.2 (G.LITE)" "ITU-T G.992.2 (G.LITE)" }; }; if (unlikely(value >= ARRAY_SIZE(str) || str[value] == NULL)) if (unlikely(value >= ARRAY_SIZE(str))) return snprintf(buf, PAGE_SIZE, "%u\n", value); return snprintf(buf, PAGE_SIZE, "%u\n", value); return snprintf(buf, PAGE_SIZE, "%s\n", str[value]); return snprintf(buf, PAGE_SIZE, "%s\n", str[value]); } } Loading