Skip to contentSkip to conversation

Reply: A null-ptr crash in linux-6.4 usb driver

DISCUSSION 柳菁峰 2 participants 2 messages Nov 8, 2023

lore
Share & tools
lore

柳菁峰

author
#0 lore raw

I have made a patch that simply checks for null pointer, but I am not sure if this will affect certain functions or logic. I hope you can check it carefully.

1006c1006
< if (dev->p->dead) {
---

Quoted 5 lines
      if (!dev->p||dev->p->dead) {

Try it and see! You have the reproducer, so you are in the best position to work on this.

#1 lore raw
Quoted 6 lines · 柳菁峰

I have made a patch that simply checks for null pointer, but I am not sure if this will affect certain functions or logic. I hope you can check it carefully.

1006c1006
< if (dev->p->dead) {
---

Quoted 1 line
      if (!dev->p||dev->p->dead) {

Can you take a look at the file, Documentation/process/submitting-patches.rst for how to properly generate a patch? This does not give us any context to even know what file you are changing.

Also, we have no context at all to even know what this is about at all, what is this for?

confused,

greg k-h