From 0ca4a10aa4e11c3c8345bc3ab8d96943ccd3f715 Mon Sep 17 00:00:00 2001 From: rltbg Date: Tue, 17 Feb 2026 13:44:11 +0100 Subject: [PATCH] working usb negociation networkmanager compatibility --- src/ch397_driver.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/ch397_driver.c b/src/ch397_driver.c index 390e2c7..e402807 100644 --- a/src/ch397_driver.c +++ b/src/ch397_driver.c @@ -29,7 +29,8 @@ struct ch397_device { }; static const struct usb_device_id ch397_table[] = { - { USB_DEVICE(CH349_VENDOR_ID, CH349_PRODUCT_ID) }, + + { USB_DEVICE(CH397_VENDOR_ID, CH397_PRODUCT_ID) }, {} }; MODULE_DEVICE_TABLE(usb, ch397_table); @@ -227,6 +228,9 @@ static int ch397_net_stop(struct net_device *netdev) netif_stop_queue(netdev); netif_carrier_off(netdev); ch397_stop_rx(dev); + + netif_carrier_off(netdev); + return 0; } @@ -307,7 +311,8 @@ static int ch397_probe(struct usb_interface *interface, int intf_num = interface->cur_altsetting->desc.bInterfaceNumber; dev_info(&interface->dev, - "Probing CH349 device (config %d, interface %d)\n", config_val, + + "Probing CH397 device (config %d, interface %d)\n", config_val, intf_num); /* @@ -424,8 +429,7 @@ static int ch397_probe(struct usb_interface *interface, dev_info(&interface->dev, "CH397 attached as %s (MAC: %pM)\n", netdev->name, mac); - //if (retval) - // goto error; + netif_carrier_off(netdev); return 0;