tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

uftdi bug?



Hello

uftdi_read() does not update the count parameter. I would expect it 
to do this:
--- sys/dev/usb/uftdi.c 11 May 2025 22:36:13 -0000      1.81
+++ sys/dev/usb/uftdi.c 21 Aug 2025 15:30:54 -0000
@@ -558,8 +558,9 @@
        }
 
        /* Adjust buffer pointer to skip status prefix */
        *ptr += 2;
+       *count -= 2;
 }
 
 static void
 uftdi_write(void *vsc, int portno, u_char *to, u_char *from, uint32_t *count)

But such a change breaks ucom. Did I misunderstood the way it should work, 
or is it a bug that is worked arond somewhere else?

-- 
Emmanuel Dreyfus
manu%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index