HID: google: add don USB id
Subsystems (9)
Sasha Levin
maintainerPATCH 1/14 HID: google: add don USB id
From: Shou-Chieh Hsu <[email protected]>
[ Upstream commit 36b87cf302a4f13f8b4344bcf98f67405a145e2f ]
Add 1 additional hammer-like device.
--- drivers/hid/hid-google-hammer.c | 2 ++ drivers/hid/hid-ids.h | 1 + 2 files changed, 3 insertions(+)
drivers/hid/hid-google-hammer.c +2 -0
@@ -467,6 +467,8 @@ static int hammer_probe(struct hid_device *hdev,static const struct hid_device_id hammer_devices[] = { + {HID_DEVICE (BUS_USB ,HID_GROUP_GENERIC , +USB_VENDOR_ID_GOOGLE ,USB_DEVICE_ID_GOOGLE_DON ) }, {HID_DEVICE (BUS_USB ,HID_GROUP_GENERIC ,USB_VENDOR_ID_GOOGLE ,USB_DEVICE_ID_GOOGLE_HAMMER ) }, { HID_DEVICE(BUS_USB, HID_GROUP_GENERIC,
drivers/hid/hid-ids.h +1 -0
@@ -488,6 +488,7 @@#define USB_DEVICE_ID_GOOGLE_MASTERBALL 0x503c#define USB_DEVICE_ID_GOOGLE_MAGNEMITE 0x503d#define USB_DEVICE_ID_GOOGLE_MOONBALL 0x5044 +#define USB_DEVICE_ID_GOOGLE_DON 0x5050#define USB_VENDOR_ID_GOTOP 0x08f2#define USB_DEVICE_ID_SUPER_Q2 0x007f
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 2/14 HID: alps: fix error return code in alps_input_configured()
From: Jia-Ju Bai <[email protected]>
[ Upstream commit fa8ba6e5dc0e78e409e503ddcfceef5dd96527f4 ]
When input_register_device() fails, no error return code is assigned. To fix this bug, ret is assigned with -ENOENT as error return code.
--- drivers/hid/hid-alps.c | 1 + 1 file changed, 1 insertion(+)
drivers/hid/hid-alps.c +1 -0
@@ -762,6 +762,7 @@ static int alps_input_configured(struct hid_device *hdev, struct hid_input *hi)if (input_register_device (data->input2)) {input_free_device (input2); + ret = -ENOENT ; goto exit; } }
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 3/14 HID: wacom: Assign boolean values to a bool variable
In reply to Sasha LevinFrom: Jiapeng Zhong <[email protected]>
[ Upstream commit e29c62ffb008829dc8bcc0a2ec438adc25a8255e ]
Fix the following coccicheck warnings:
./drivers/hid/wacom_wac.c:2536:2-6: WARNING: Assignment of 0/1 to bool variable.
--- drivers/hid/wacom_wac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/hid/wacom_wac.c +1 -1
@@ -2533,7 +2533,7 @@ static void wacom_wac_finger_slot(struct wacom_wac *wacom_wac, !wacom_wac->shared->is_touch_on) {if (!wacom_wac->shared->touch_down)return ; - prox =0 ; + prox = false; } wacom_wac->hid_data.num_received++;
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 4/14 ARM: dts: Fix swapped mmc order for omap3
In reply to Sasha LevinFrom: Tony Lindgren <[email protected]>
[ Upstream commit a1ebdb3741993f853865d1bd8f77881916ad53a7 ]
Also some omap3 devices like n900 seem to have eMMC and micro-sd swapped around with commit 21b2cec61c04 ("mmc: Set PROBE_PREFER_ASYNCHRONOUS for drivers that existed in v4.4").
Let's fix the issue with aliases as discussed on the mailing lists. While the mmc aliases should be board specific, let's first fix the issue with minimal changes.
--- arch/arm/boot/dts/omap3.dtsi | 3 +++ 1 file changed, 3 insertions(+)
arch/arm/boot/dts/omap3.dtsi +3 -0
@@ -23,6 +23,9 @@ aliases { i2c0 = &i2c1; i2c1 = &i2c2; i2c2 = &i2c3; + mmc0 = &mmc1; + mmc1 = &mmc2; + mmc2 = &mmc3; serial0 = &uart1; serial1 = &uart2; serial2 = &uart3;
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 5/14 net: geneve: check skb is large enough for IPv4/IPv6 header
In reply to Sasha LevinFrom: Phillip Potter <[email protected]>
[ Upstream commit 6628ddfec7580882f11fdc5c194a8ea781fdadfa ]
Check within geneve_xmit_skb/geneve6_xmit_skb that sk_buff structure is large enough to include IPv4 or IPv6 header, and reject if not. The geneve_xmit_skb portion and overall idea was contributed by Eric Dumazet. Fixes a KMSAN-found uninit-value bug reported by syzbot at:
https://syzkaller.appspot.com/bug?id=abe95dc3e3e9667fc23b8d81f29ecad95c6f106f
--- drivers/net/geneve.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/net/geneve.c +6 -0
@@ -891,6 +891,9 @@ static int geneve_xmit_skb(struct sk_buff *skb, struct net_device *dev,__be16 sport;int err; +if (!pskb_network_may_pull (skb,sizeof (struct iphdr ))) +return -EINVAL ; + sport =udp_flow_src_port (geneve->net, skb,1 ,USHRT_MAX , true); rt =geneve_get_v4_rt (skb, dev, gs4, &fl4, info, geneve->info.key.tp_dst, sport);
@@ -954,6 +957,9 @@ static int geneve6_xmit_skb(struct sk_buff *skb, struct net_device *dev,__be16 sport;int err; +if (!pskb_network_may_pull (skb,sizeof (struct ipv6hdr ))) +return -EINVAL ; + sport =udp_flow_src_port (geneve->net, skb,1 ,USHRT_MAX , true); dst =geneve_get_v6_dst (skb, dev, gs6, &fl6, info, geneve->info.key.tp_dst, sport);
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 6/14 s390/entry: save the caller of psw_idle
In reply to Sasha LevinFrom: Vasily Gorbik <[email protected]>
[ Upstream commit a994eddb947ea9ebb7b14d9a1267001699f0a136 ]
Currently psw_idle does not allocate a stack frame and does not save its r14 and r15 into the save area. Even though this is valid from call ABI point of view, because psw_idle does not make any calls explicitly, in reality psw_idle is an entry point for controlled transition into serving interrupts. So, in practice, psw_idle stack frame is analyzed during stack unwinding. Depending on build options that r14 slot in the save area of psw_idle might either contain a value saved by previous sibling call or complete garbage.
[task 0000038000003c28] do_ext_irq+0xd6/0x160
[task 0000038000003c78] ext_int_handler+0xba/0xe8
[task *0000038000003dd8] psw_idle_exit+0x0/0x8 <-- pt_regs
([task 0000038000003dd8] 0x0) [task 0000038000003e10] default_idle_call+0x42/0x148 [task 0000038000003e30] do_idle+0xce/0x160 [task 0000038000003e70] cpu_startup_entry+0x36/0x40 [task 0000038000003ea0] arch_call_rest_init+0x76/0x80
So, to make a stacktrace nicer and actually point for the real caller of psw_idle in this frequently occurring case, make psw_idle save its r14.
[task 0000038000003c28] do_ext_irq+0xd6/0x160
[task 0000038000003c78] ext_int_handler+0xba/0xe8
[task *0000038000003dd8] psw_idle_exit+0x0/0x6 <-- pt_regs
([task 0000038000003dd8] arch_cpu_idle+0x3c/0xd0) [task 0000038000003e10] default_idle_call+0x42/0x148 [task 0000038000003e30] do_idle+0xce/0x160 [task 0000038000003e70] cpu_startup_entry+0x36/0x40 [task 0000038000003ea0] arch_call_rest_init+0x76/0x80
--- arch/s390/kernel/entry.S | 1 + 1 file changed, 1 insertion(+)
arch/s390/kernel/entry.S +1 -0
@@ -993,6 +993,7 @@ ENDPROC(ext_int_handler) * Load idle PSW. The second "half" of this function is in .Lcleanup_idle. */ ENTRY(psw_idle) + stg %r14,(__SF_GPRS+8*8)(%r15) stg %r3,__SF_EMPTY(%r15) larl %r1,.Lpsw_idle_lpsw+4 stg %r1,__SF_EMPTY+8(%r15)
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 7/14 xen-netback: Check for hotplug-status existence before watching
In reply to Sasha LevinFrom: Michael Brown <[email protected]>
[ Upstream commit 2afeec08ab5c86ae21952151f726bfe184f6b23d ]
The logic in connect() is currently written with the assumption that xenbus_watch_pathfmt() will return an error for a node that does not exist. This assumption is incorrect: xenstore does allow a watch to be registered for a nonexistent node (and will send notifications should the node be subsequently created).
As of commit 1f2565780 ("xen-netback: remove 'hotplug-status' once it has served its purpose"), this leads to a failure when a domU transitions into XenbusStateConnected more than once. On the first domU transition into Connected state, the "hotplug-status" node will be deleted by the hotplug_status_changed() callback in dom0. On the second or subsequent domU transition into Connected state, the hotplug_status_changed() callback will therefore never be invoked, and so the backend will remain stuck in InitWait.
This failure prevents scenarios such as reloading the xen-netfront module within a domU, or booting a domU via iPXE. There is unfortunately no way for the domU to work around this dom0 bug.
Fix by explicitly checking for existence of the "hotplug-status" node, thereby creating the behaviour that was previously assumed to exist.
--- drivers/net/xen-netback/xenbus.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-)
drivers/net/xen-netback/xenbus.c +8 -4
@@ -979,11 +979,15 @@ static void connect(struct backend_info *be)xenvif_carrier_on (be->vif);unregister_hotplug_status_watch (be); - err =xenbus_watch_pathfmt (dev, &be->hotplug_status_watch,NULL , - hotplug_status_changed, -"%s/%s" , dev->nodename,"hotplug-status" ); -if (!err) +if (xenbus_exists (XBT_NIL , dev->nodename,"hotplug-status" )) { + err =xenbus_watch_pathfmt (dev, &be->hotplug_status_watch, +NULL , hotplug_status_changed, +"%s/%s" , dev->nodename, +"hotplug-status" ); +if (err) + goto err; be->have_hotplug_status_watch =1 ; + }netif_tx_wake_all_queues (be->vif->dev);
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 8/14 cavium/liquidio: Fix duplicate argument
In reply to Sasha LevinFrom: Wan Jiabing <[email protected]>
[ Upstream commit 416dcc5ce9d2a810477171c62ffa061a98f87367 ]
Fix the following coccicheck warning:
./drivers/net/ethernet/cavium/liquidio/cn66xx_regs.h:413:6-28:
duplicated argument to & or |
The CN6XXX_INTR_M1UPB0_ERR here is duplicate. Here should be CN6XXX_INTR_M1UNB0_ERR.
--- drivers/net/ethernet/cavium/liquidio/cn66xx_regs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/cavium/liquidio/cn66xx_regs.h +1 -1
@@ -412,7 +412,7 @@ | CN6XXX_INTR_M0UNWI_ERR \ |CN6XXX_INTR_M1UPB0_ERR \ |CN6XXX_INTR_M1UPWI_ERR \ - |CN6XXX_INTR_M1UPB0_ERR \ + |CN6XXX_INTR_M1UNB0_ERR \ |CN6XXX_INTR_M1UNWI_ERR \ |CN6XXX_INTR_INSTR_DB_OF_ERR \ |CN6XXX_INTR_SLIST_DB_OF_ERR \
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 9/14 i2c: mv64xxx: Fix random system lock caused by runtime PM
In reply to Sasha LevinFrom: Marek Behún <[email protected]>
[ Upstream commit 39930213e7779b9c4257499972b8afb8858f1a2d ]
I noticed a weird bug with this driver on Marvell CN9130 Customer Reference Board.
Sometime after boot, the system locks with the following message:
[104.071363] i2c i2c-0: mv64xxx: I2C bus locked, block: 1, time_left: 0
The system does not respond afterwards, only warns about RCU stalls.
This first appeared with commit e5c02cf54154 ("i2c: mv64xxx: Add runtime PM support").
With further experimentation I discovered that adding a delay into mv64xxx_i2c_hw_init() fixes this issue. This function is called before every xfer, due to how runtime PM works in this driver. It seems that in order to work correctly, a delay is needed after the bus is reset in this function.
Since there already is a known erratum with this controller needing a delay, I assume that this is just another place this needs to be applied. Therefore I apply the delay only if errata_delay is true.
--- drivers/i2c/busses/i2c-mv64xxx.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/i2c/busses/i2c-mv64xxx.c +4 -0
@@ -218,6 +218,10 @@ mv64xxx_i2c_hw_init(struct mv64xxx_i2c_data *drv_data)writel (0 , drv_data->reg_base + drv_data->reg_offsets.ext_addr);writel (MV64XXX_I2C_REG_CONTROL_TWSIEN |MV64XXX_I2C_REG_CONTROL_STOP , drv_data->reg_base + drv_data->reg_offsets.control); + +if (drv_data->errata_delay) +udelay (5 ); + drv_data->state =MV64XXX_I2C_STATE_IDLE ; }
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 10/14 csky: change a Kconfig symbol name to fix e1000 build error
In reply to Sasha LevinFrom: Randy Dunlap <[email protected]>
[ Upstream commit d199161653d612b8fb96ac51bfd5b2d2782ecef3 ]
e1000's #define of CONFIG_RAM_BASE conflicts with a Kconfig symbol in arch/csky/Kconfig.
The symbol in e1000 has been around longer, so change arch/csky/ to use DRAM_BASE instead of RAM_BASE to remove the conflict. (although e1000 is also a 2-line change)
--- arch/csky/Kconfig | 2 +- arch/csky/include/asm/page.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/csky/Kconfig +1 -1
@@ -220,7 +220,7 @@ config FORCE_MAX_ZONEORDER int "Maximum zone order" default "11" -config RAM_BASE +config DRAM_BASE hex "DRAM start addr (the same with memory-section in dts)" default 0x0
arch/csky/include/asm/page.h +1 -1
@@ -28,7 +28,7 @@#define SSEG_SIZE 0x20000000#define LOWMEM_LIMIT (SSEG_SIZE * 2) -#define PHYS_OFFSET_OFFSET (CONFIG_RAM_BASE & (SSEG_SIZE - 1)) +#define PHYS_OFFSET_OFFSET (CONFIG_DRAM_BASE & (SSEG_SIZE - 1))#ifndef __ASSEMBLY__
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 11/14 ia64: fix discontig.c section mismatches
In reply to Sasha LevinFrom: Randy Dunlap <[email protected]>
[ Upstream commit e2af9da4f867a1a54f1252bf3abc1a5c63951778 ]
Fix IA64 discontig.c Section mismatch warnings.
When CONFIG_SPARSEMEM=y and CONFIG_MEMORY_HOTPLUG=y, the functions computer_pernodesize() and scatter_node_data() should not be marked as __meminit because they are needed after init, on any memory hotplug event. Also, early_nr_cpus_node() is called by compute_pernodesize(), so early_nr_cpus_node() cannot be __meminit either.
WARNING: modpost: vmlinux.o(.text.unlikely+0x1612): Section mismatch in reference from the function arch_alloc_nodedata() to the function .meminit.text:compute_pernodesize() The function arch_alloc_nodedata() references the function __meminit compute_pernodesize().
This is often because arch_alloc_nodedata lacks a __meminit annotation or the annotation of compute_pernodesize is wrong.
WARNING: modpost: vmlinux.o(.text.unlikely+0x1692): Section mismatch in reference from the function arch_refresh_nodedata() to the function .meminit.text:scatter_node_data() The function arch_refresh_nodedata() references the function __meminit scatter_node_data().
This is often because arch_refresh_nodedata lacks a __meminit annotation or the annotation of scatter_node_data is wrong.
WARNING: modpost: vmlinux.o(.text.unlikely+0x1502): Section mismatch in reference from the function compute_pernodesize() to the function .meminit.text:early_nr_cpus_node() The function compute_pernodesize() references the function __meminit early_nr_cpus_node().
This is often because compute_pernodesize lacks a __meminit annotation or the annotation of early_nr_cpus_node is wrong.
--- arch/ia64/mm/discontig.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
arch/ia64/mm/discontig.c +3 -3
@@ -95,7 +95,7 @@ static int __init build_node_maps(unsigned long start, unsigned long len,* acpi_boot_init() (which builds the node_to_cpu_mask array) hasn't been * called yet. Note that node 0 will also count all non-existent cpus. */ -static int __meminit early_nr_cpus_node (int node) +static int early_nr_cpus_node (int node) {int cpu, n =0 ;
@@ -110,7 +110,7 @@ static int __meminit early_nr_cpus_node(int node)* compute_pernodesize - compute size of pernode data * @node: the node id. */ -static unsigned long __meminit compute_pernodesize (int node) +static unsigned long compute_pernodesize (int node) {unsigned long pernodesize =0 , cpus;
@@ -367,7 +367,7 @@ static void __init reserve_pernode_space(void) } } -static void __meminit scatter_node_data (void ) +static void scatter_node_data (void ) {pg_data_t **dst;int node;
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 12/14 ia64: tools: remove duplicate definition of ia64_mf() on ia64
In reply to Sasha LevinFrom: John Paul Adrian Glaubitz <[email protected]>
[ Upstream commit f4bf09dc3aaa4b07cd15630f2023f68cb2668809 ]
The ia64_mf() macro defined in tools/arch/ia64/include/asm/barrier.h is already defined in <asm/gcc_intrin.h> on ia64 which causes libbpf failing to build:
CC /usr/src/linux/tools/bpf/bpftool//libbpf/staticobjs/libbpf.o
In file included from /usr/src/linux/tools/include/asm/barrier.h:24,
from /usr/src/linux/tools/include/linux/ring_buffer.h:4,
from libbpf.c:37:
/usr/src/linux/tools/include/asm/../../arch/ia64/include/asm/barrier.h:43: error: "ia64_mf" redefined [-Werror]
43 | #define ia64_mf() asm volatile ("mf" ::: "memory")
|
In file included from /usr/include/ia64-linux-gnu/asm/intrinsics.h:20,
from /usr/include/ia64-linux-gnu/asm/swab.h:11,
from /usr/include/linux/swab.h:8,
from /usr/include/linux/byteorder/little_endian.h:13,
from /usr/include/ia64-linux-gnu/asm/byteorder.h:5,
from /usr/src/linux/tools/include/uapi/linux/perf_event.h:20,
from libbpf.c:36:
/usr/include/ia64-linux-gnu/asm/gcc_intrin.h:382: note: this is the location of the previous definition
382 | #define ia64_mf() __asm__ volatile ("mf" ::: "memory")
|cc1: all warnings being treated as errors
Thus, remove the definition from tools/arch/ia64/include/asm/barrier.h.
--- tools/arch/ia64/include/asm/barrier.h | 3 --- 1 file changed, 3 deletions(-)
tools/arch/ia64/include/asm/barrier.h +0 -3
@@ -39,9 +39,6 @@* sequential memory pages only. */ -/* XXX From arch/ia64/include/uapi/asm/gcc_intrin.h */ -#define ia64_mf () asm volatile ("mf" ::: "memory") -#define mb () ia64_mf()#define rmb () mb()#define wmb () mb()
Signature · 1 line
2.30.2
Sasha Levin
maintainerPATCH 13/14 gcov: clang: fix clang-11+ build
In reply to Sasha LevinFrom: Johannes Berg <[email protected]>
[ Upstream commit 04c53de57cb6435738961dace8b1b71d3ecd3c39 ]
With clang-11+, the code is broken due to my kvmalloc() conversion (which predated the clang-11 support code) leaving one vmalloc() in place. Fix that.
--- kernel/gcov/clang.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/gcov/clang.c +1 -1
@@ -369,7 +369,7 @@ static struct gcov_fn_info *gcov_fn_info_dup(struct gcov_fn_info *fn)INIT_LIST_HEAD (&fn_dup->head); cv_size = fn->num_counters *sizeof (fn->counters[0 ]); - fn_dup->counters =vmalloc (cv_size); + fn_dup->counters =kvmalloc (cv_size,GFP_KERNEL );if (!fn_dup->counters) {kfree (fn_dup);return NULL ;
Signature · 1 line
2.30.2
Re: [PATCH AUTOSEL 5.4 13/14] gcov: clang: fix clang-11+ build
Quoted 7 lines · Sasha Levin
From: Johannes Berg <[email protected]>
[ Upstream commit
04c53de57cb6435738961dace8b1b71d3ecd3c39]With clang-11+, the code is broken due to my
kvmalloc()conversion (which predated the clang-11 support code) leaving onevmalloc()in place. Fix that.
This patch might *apply* on 5.4 (and the other kernels you selected it for), but then I'm pretty sure it'll be broken, unless you also applied the various patches this was actually fixing (my kvmalloc conversion, and the clang-11 support).
Also, Linus has (correctly) reverted this patch from mainline, it shouldn't have gone there in the first place, probably really should be squashed into my kvmalloc conversion patch that's in -mm now.
Sorry if I didn't make that clear enough at the time.
In any case, please drop this patch from all stable trees.
johannes
Sasha Levin
maintainerRe: [PATCH AUTOSEL 5.4 13/14] gcov: clang: fix clang-11+ build
Quoted 14 lines · Johannes Berg
Quoted 7 lines · Sasha Levin
From: Johannes Berg <[email protected]>
[ Upstream commit
04c53de57cb6435738961dace8b1b71d3ecd3c39]With clang-11+, the code is broken due to my
kvmalloc()conversion (which predated the clang-11 support code) leaving onevmalloc()in place. Fix that.This patch might *apply* on 5.4 (and the other kernels you selected it for), but then I'm pretty sure it'll be broken, unless you also applied the various patches this was actually fixing (my kvmalloc conversion, and the clang-11 support).
Quoted 8 lines
Also, Linus has (correctly) reverted this patch from mainline, it shouldn't have gone there in the first place, probably really should be squashed into my kvmalloc conversion patch that's in -mm now.
Sorry if I didn't make that clear enough at the time.
In any case, please drop this patch from all stable trees.
Will do, thanks!
Signature · 2 lines
Thanks, Sasha
Sasha Levin
maintainerPATCH 14/14 readdir: make sure to verify directory entry for legacy interfaces too
In reply to Sasha LevinFrom: Linus Torvalds <[email protected]>
[ Upstream commit 0c93ac69407d63a85be0129aa55ffaec27ffebd3 ]
This does the directory entry name verification for the legacy "fillonedir" (and compat) interface that goes all the way back to the dark ages before we had a proper dirent, and the readdir() system call returned just a single entry at a time.
Nobody should use this interface unless you still have binaries from 1991, but let's do it right.
This came up during discussions about unsafe_copy_to_user() and proper checking of all the inputs to it, as the networking layer is looking to use it in a few new places. So let's make sure the _old_ users do it all right and proper, before we add new ones.
See also commit 8a23eb804ca4 ("Make filldir[64]() verify the directory entry filename is valid") which did the proper modern interfaces that people actually use. It had a note:
Note that I didn't bother adding the checks to any legacy interfaces that nobody uses.
which this now corrects. Note that we really don't care about POSIX and the presense of '/' in a directory entry, but verify_dirent_name() also ends up doing the proper name length verification which is what the input checking discussion was about.
[ Another option would be to remove the support for this particular very
old interface: any binaries that use it are likely a.out binaries, and they will no longer run anyway since we removed a.out binftm support in commit eac616557050 ("x86: Deprecate a.out support").
But I'm not sure which came first: getdents() or ELF support, so let's pretend somebody might still have a working binary that uses the legacy readdir() case.. ]
--- fs/readdir.c | 6 ++++++ 1 file changed, 6 insertions(+)
fs/readdir.c +6 -0
@@ -150,6 +150,9 @@ static int fillonedir(struct dir_context *ctx, const char *name, int namlen,if (buf->result)return -EINVAL ; + buf->result =verify_dirent_name (name, namlen); +if (buf->result <0 ) +return buf->result; d_ino = ino;if (sizeof (d_ino) <sizeof (ino) && d_ino != ino) { buf->result = -EOVERFLOW ;
@@ -417,6 +420,9 @@ static int compat_fillonedir(struct dir_context *ctx, const char *name,if (buf->result)return -EINVAL ; + buf->result =verify_dirent_name (name, namlen); +if (buf->result <0 ) +return buf->result; d_ino = ino;if (sizeof (d_ino) <sizeof (ino) && d_ino != ino) { buf->result = -EOVERFLOW ;
Signature · 1 line
2.30.2