From patchwork Wed Sep 4 22:27:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Stefan_M=C3=A4tje?= X-Patchwork-Id: 13791472 X-Patchwork-Delegate: kuba@kernel.org Received: from AM0PR83CU005.outbound.protection.outlook.com (mail-westeuropeazon11020095.outbound.protection.outlook.com [52.101.69.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 07BAB17B4E5; Wed, 4 Sep 2024 22:27:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.69.95 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1725488871; cv=fail; b=lqywUAu8UhXE6w6Sk6AutDJxSAXolWWMueIugiBAD6E058BujtSZMp1oem4f3NyIcHIxJx8QmmcD8Lt/Kq0PoAzF1ZAebXWzTm0ptXDdi838gUWoWKG394wzJ9K+jIaLtCWF/ejORannr7NGzGhrFpoFRexeCxnIpvJin2rYz6o= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1725488871; c=relaxed/simple; bh=ff0uevsRtp8ADwP9dSytnxNYhFmSQCYkiWEbACFit90=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Type; b=X/1nsw1s922BNSRk5LYf4AD5KrclMErVOKo4hyobNavjYGb19RT/aOzr1of7rHexjfxgS56tvk64kRr/EV90yqx2SPV7f7aN3hHkFOSzdQbtf+zdZQfX1B1AqfEciyptEcEzK4DhCOdodN7uxplDOWdfh008rvl0tnKgdkAo6I4= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=esd.eu; spf=pass smtp.mailfrom=esd.eu; dkim=pass (1024-bit key) header.d=esdhannover.onmicrosoft.com header.i=@esdhannover.onmicrosoft.com header.b=olBRnpRz; arc=fail smtp.client-ip=52.101.69.95 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=esd.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=esd.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=esdhannover.onmicrosoft.com header.i=@esdhannover.onmicrosoft.com header.b="olBRnpRz" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Xr6kUi+6FIh3mVibzsu1uB2ryMPovE6KwFMdcnRCYkNy0VdFX7McUHgrETQU+Jiqf3jv9YVyox3H/KyLNS+QjiPr7S0d5Zd3WAl4MtS/DESMIBGcroDNpDdKErelivhmXMorikvO7PV/zdn2XNb6MsT3wMN9II4kB1VO+JHej/C4F2GsDWJ9MzG0i1kFiWiXa0KImIyRClKFj3oxfiNM5aiPRaPjuyMS9PwY2F2NgrucCPx78agLc8BK4I8ZcRX9yYK1kxsFgvTkXwELgglM0TrOKtQMnxSI4Y4cyZbCHv/a7tRoq2xj4OeDXx/UCfo+5GPzJNUuydWnBO4OvoHruQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0wvwlgfFiCWSsXUZ1bPuClLh8oSAUAhZyBW3ycn/glo=; b=TgYYc1nN+qZltqCxUxSXt0a/BH1lpr19i8X+OE7ZEWftiyHcCmXsSoAx0cPuEkNI1JO/5kIzl4qsr5jAEoNE+yrL4oBx2CrRRg1gc2Itq4+oe168t2V2tVQ+QbFhTfhZMGHuoRMBVC6GrdImwIXWFmAtz35dv7BTl859MXLC+AuEFSSmSsMgU3XmHz3s/rMzMBMy08ziTFTDfJXEKNZHaPcxMZVvGkNaQJMvxRKOzMsJuXIqOEqQir1vS4MNt8hG04y0bl6Z2gb/EgTbzOsGvIalnSlW699GckWy2GVXEKnP/Wi6ZgcZhMmVaepCWSIrH/SSeImsFg3ff5Eh9Rlpqg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=softfail (sender ip is 80.151.164.27) smtp.rcpttodomain=davemloft.net smtp.mailfrom=esd.eu; dmarc=fail (p=none sp=none pct=100) action=none header.from=esd.eu; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=esdhannover.onmicrosoft.com; s=selector1-esdhannover-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0wvwlgfFiCWSsXUZ1bPuClLh8oSAUAhZyBW3ycn/glo=; b=olBRnpRz5C8UToCA4Wh2gY0UWywm+Dq9lDGVQIxbC/oYbVGP/WyJbLfHOaim1ECEmhiFxBW7oRYHdOTRn5zD9H2dpdVEpCdUComfHf79ZHpDGRSn+j0Vl6kgLGJfsY6CvWOSm6bX+UQvRBt50ZOIXOCT5q08J3Uu+CAECfff90Q= Received: from DUZP191CA0066.EURP191.PROD.OUTLOOK.COM (2603:10a6:10:4fa::9) by PR3PR03MB6617.eurprd03.prod.outlook.com (2603:10a6:102:7f::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7918.25; Wed, 4 Sep 2024 22:27:42 +0000 Received: from DU2PEPF00028CFC.eurprd03.prod.outlook.com (2603:10a6:10:4fa:cafe::d8) by DUZP191CA0066.outlook.office365.com (2603:10a6:10:4fa::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7918.27 via Frontend Transport; Wed, 4 Sep 2024 22:27:42 +0000 X-MS-Exchange-Authentication-Results: spf=softfail (sender IP is 80.151.164.27) smtp.mailfrom=esd.eu; dkim=none (message not signed) header.d=none;dmarc=fail action=none header.from=esd.eu; Received-SPF: SoftFail (protection.outlook.com: domain of transitioning esd.eu discourages use of 80.151.164.27 as permitted sender) Received: from esd-s7.esd (80.151.164.27) by DU2PEPF00028CFC.mail.protection.outlook.com (10.167.242.180) with Microsoft SMTP Server id 15.20.7918.13 via Frontend Transport; Wed, 4 Sep 2024 22:27:41 +0000 Received: from debby.esd.local (debby [10.0.0.190]) by esd-s7.esd (Postfix) with ESMTPS id B7D447C16C8; Thu, 5 Sep 2024 00:27:40 +0200 (CEST) Received: by debby.esd.local (Postfix, from userid 2044) id A126F2E17AF; Thu, 5 Sep 2024 00:27:40 +0200 (CEST) From: =?utf-8?q?Stefan_M=C3=A4tje?= To: Marc Kleine-Budde , Vincent Mailhol , Frank Jungclaus , linux-can@vger.kernel.org Cc: netdev@vger.kernel.org, "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman , stable@vger.kernel.org Subject: [PATCH 1/1] can: esd_usb: Remove CAN_CTRLMODE_3_SAMPLES for CAN-USB/3-FD Date: Thu, 5 Sep 2024 00:27:40 +0200 Message-Id: <20240904222740.2985864-2-stefan.maetje@esd.eu> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20240904222740.2985864-1-stefan.maetje@esd.eu> References: <20240904222740.2985864-1-stefan.maetje@esd.eu> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU2PEPF00028CFC:EE_|PR3PR03MB6617:EE_ X-MS-Office365-Filtering-Correlation-Id: 36c1eb55-546b-4c07-15d3-08dccd30ca04 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|36860700013|376014|7416014|82310400026|1800799024; X-Microsoft-Antispam-Message-Info: =?utf-8?q?GXvNoJ63H9ZQKpd+wuIvq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5GCXV51aX9WYus?= =?utf-8?q?H3Cgr3npvBfbAv2nLxMAsNk5lnDZXd+1jwdQKmbWB+DxCd6gd/TN23OrCVnCg+a7p?= =?utf-8?q?pjeM/sIxlDVlJeyqNrh8AchQ+SmaG1Nd4ngjnUJZAj7kX5Xa436J7lgpBhNKsxzI4?= =?utf-8?q?8VMRq986C+pdF69ZDKIXjEomv9aYkyRRV/nJHTTSr0Y4CWK8tiY51dg1jEhyzI0yK?= =?utf-8?q?1qEb8Whw2X22Do0yUuV0u8/4UT0VWjLifQZPq06uFI6R8+ViofeFC/An6op8IUVxY?= =?utf-8?q?emYhURhf3z/a0ChUiQyn6jaMoHDsw8Kp26C2d6XlR0Ot1+wbckZHNOACzqvX0GPcc?= =?utf-8?q?BbVc2etRyscQnA9yWQOrY/YrdO35XJqKq8bO8oz7H2oCHaiw4/nAsnsb1K89th9FA?= =?utf-8?q?VoCHoydcUAQa0y4SsODelVzx06hraOxyVW1mCq/hmBSyD5euu+0jpFO7Q798v9r0n?= =?utf-8?q?BvthplXoRwPAv3iZMkaF4oKsQBxWw3v35s4ndOozD8YdCp5CPUPtkahDoXJZlJWj2?= =?utf-8?q?mYFdZXBrz1q?= X-Forefront-Antispam-Report: CIP:80.151.164.27;CTRY:DE;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:esd-s7.esd;PTR:p5097a41b.dip0.t-ipconnect.de;CAT:NONE;SFS:(13230040)(36860700013)(376014)(7416014)(82310400026)(1800799024);DIR:OUT;SFP:1102; X-OriginatorOrg: esd.eu X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Sep 2024 22:27:41.0063 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 36c1eb55-546b-4c07-15d3-08dccd30ca04 X-MS-Exchange-CrossTenant-Id: 5a9c3a1d-52db-4235-b74c-9fd851db2e6b X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5a9c3a1d-52db-4235-b74c-9fd851db2e6b;Ip=[80.151.164.27];Helo=[esd-s7.esd] X-MS-Exchange-CrossTenant-AuthSource: DU2PEPF00028CFC.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PR3PR03MB6617 X-Patchwork-Delegate: kuba@kernel.org Remove the CAN_CTRLMODE_3_SAMPLES announcement for CAN-USB/3-FD devices because these devices don't support it. The hardware has a Microchip SAM E70 microcontroller that uses a Bosch MCAN IP core as CAN FD controller. But this MCAN core doesn't support triple sampling. Fixes: 80662d943075 ("can: esd_usb: Add support for esd CAN-USB/3") Cc: stable@vger.kernel.org Signed-off-by: Stefan Mätje Reviewed-by: Vincent Mailhol --- drivers/net/can/usb/esd_usb.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/net/can/usb/esd_usb.c b/drivers/net/can/usb/esd_usb.c index 41a0e4261d15..03ad10b01867 100644 --- a/drivers/net/can/usb/esd_usb.c +++ b/drivers/net/can/usb/esd_usb.c @@ -3,7 +3,7 @@ * CAN driver for esd electronics gmbh CAN-USB/2, CAN-USB/3 and CAN-USB/Micro * * Copyright (C) 2010-2012 esd electronic system design gmbh, Matthias Fuchs - * Copyright (C) 2022-2023 esd electronics gmbh, Frank Jungclaus + * Copyright (C) 2022-2024 esd electronics gmbh, Frank Jungclaus */ #include @@ -1116,9 +1116,6 @@ static int esd_usb_3_set_bittiming(struct net_device *netdev) if (priv->can.ctrlmode & CAN_CTRLMODE_LISTENONLY) flags |= ESD_USB_3_BAUDRATE_FLAG_LOM; - if (priv->can.ctrlmode & CAN_CTRLMODE_3_SAMPLES) - flags |= ESD_USB_3_BAUDRATE_FLAG_TRS; - baud_x->nom.brp = cpu_to_le16(nom_bt->brp & (nom_btc->brp_max - 1)); baud_x->nom.sjw = cpu_to_le16(nom_bt->sjw & (nom_btc->sjw_max - 1)); baud_x->nom.tseg1 = cpu_to_le16((nom_bt->prop_seg + nom_bt->phase_seg1) @@ -1219,7 +1216,6 @@ static int esd_usb_probe_one_net(struct usb_interface *intf, int index) switch (le16_to_cpu(dev->udev->descriptor.idProduct)) { case ESD_USB_CANUSB3_PRODUCT_ID: priv->can.clock.freq = ESD_USB_3_CAN_CLOCK; - priv->can.ctrlmode_supported |= CAN_CTRLMODE_3_SAMPLES; priv->can.ctrlmode_supported |= CAN_CTRLMODE_FD; priv->can.bittiming_const = &esd_usb_3_nom_bittiming_const; priv->can.data_bittiming_const = &esd_usb_3_data_bittiming_const;