From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ej1-f42.google.com (mail-ej1-f42.google.com [209.85.218.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 314FE1F80D1 for ; Tue, 15 Oct 2024 19:17:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.42 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019834; cv=none; b=Y5ZVnBE/kKK/kLB8dg8EfbUWsDLoKsLRmV7h9lfa6OMim1D9FPCg89j9bWyMDN1Gc2ubjN7ubseyK3sOju4W8zIerfjpIsdEuyArEzkjEpUZeJ2mFPPRasNuEYaPuqwKd9AerhMayNdQXFrTUxrbCXwNu1WT0/hYaCSITVDr6Ak= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019834; c=relaxed/simple; bh=Jw+WdBzdeJ1ejN6JFooZdebJTss0hVEiqW0IkRTOyf4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=php6s+cCn1kHiYBB3n+MVCz+QOYc9DuQF2eDrRHF9Fy8aw45VcPPklWN5+/kANfrqviYsleapMkp8RuALZ8kQkECMBa0nO5ERZzlPAhKCv4J2rw+11ZDUHq7plubcUW4GsbcmawebCmZzqabXAce2AoGLkufO0iQRi3vLvDIZUY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=yQaNsijE; arc=none smtp.client-ip=209.85.218.42 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="yQaNsijE" Received: by mail-ej1-f42.google.com with SMTP id a640c23a62f3a-a9a2cdc6f0cso149190466b.2 for ; Tue, 15 Oct 2024 12:17:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019830; x=1729624630; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=BosgQ+kD0H5BJCs43wOOr0oQ/yjsIN/cdckDvbryFCI=; b=yQaNsijE1PZ/e4b4fOvo0oEiUo84DNtinRmfG84VSrHQAcu+zmXyojK0n7raycgRmw VwU1Dh8Vny3PizuUu2v7JHoQGjE8lkNZUzby6T8vYVek3mvaW6kLLILpQCQWkAQ/HsXE TquicYi7uOTBLkFbU9w6j8eoNDyQGFCsVPCkn9GAkHq/Ad0ieZiQZUFYhqrli09UpoBk asAvC9i8lT1KI0SU1/99uAK8HjMTMXBHYypK3210cd1YgKNtScDmorYuEtcfdAj9l/8x yczlG8oNFcQPktg3vr/qKaomsn3fCLQfw890LalN5iw3nelaCuBQj8/aaBlKoX2xbQmN 7/iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019830; x=1729624630; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BosgQ+kD0H5BJCs43wOOr0oQ/yjsIN/cdckDvbryFCI=; b=hHH+kUJGi4n9XpwudhgRNZKeRkAAJEjpdRa3+B+m2Oq8Ct4J/7caFRsxHB+aLJ6TCN eflm6SylMRTBJqtBhs5XstCH+obvqOi6ry8MvzvqEKo6k9Ibqmj0ZU/U6bOovjdGOWoE C7Gute+bJrERGofyjR/dNnzbHL6TqbdWWUNDLjWNT1/wNtOfvc9SM7Hsx84gcM4RqVtx tHu0JZQT48DGHJoAoXGfRnttcyWeAT8X+JYMsdejZDpeJ3KgihgT6S3R/n3SKHsNqT52 rcsyL8k3ye67i326hEeb/8tKDfOqjGT9/sps9UED8jeSRBeSeCidYDTkJZrzRjtY/I8/ WSXg== X-Forwarded-Encrypted: i=1; AJvYcCW/8k3bEf/TPx4qgLb+doh2KMME9af5LPpmhno2cjCjtDoR1lunogqmqbh58Pm5n9Hp/6nh4baGcjaWYRg=@vger.kernel.org X-Gm-Message-State: AOJu0YxJptjOLtPXd0id1cGByxyxoPn+60Db4sZ8f6nmJc70Twxw7MLi xUeUzpFlG28FvU+CDD2NRIB71/mepWxpJJ3ognQC+oz2zVRMCMVLtj0ux5mLH14= X-Google-Smtp-Source: AGHT+IFsYtA77wAuh9nis+Oc6a+Lfq19dmpQld1Bd4sJ531FzQwGqpJkoSD0d+dwGzwE0A/GIUGxDg== X-Received: by 2002:a17:907:7291:b0:a99:f4eb:b7ee with SMTP id a640c23a62f3a-a99f4ebba87mr1017022866b.11.1729019830501; Tue, 15 Oct 2024 12:17:10 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a2971a51esm101941966b.37.2024.10.15.12.17.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:10 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:15:55 +0200 Subject: [PATCH v4 1/9] dt-bindings: can: m_can: Add wakeup properties Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-1-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann , Krzysztof Kozlowski X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1874; i=msp@baylibre.com; h=from:subject:message-id; bh=Jw+WdBzdeJ1ejN6JFooZdebJTss0hVEiqW0IkRTOyf4=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59rcHTtJ/VpO3mLlHjY0r6UKy1A873eMXXD+4bivaV Ki43HxfRykLgxgHg6yYIsvdDwvf1cldXxCx7pEjzBxWJpAhDFycAjCRr8YM/2uytik0z7co6z+5 f/NiuZi2pwwypzN/bHXdcr3Nb0XR61uMDP3xIbNWWVbbZBsf/XOsQtx5goxrOr+e+ryluV37PbJ OswAA X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 m_can can be a wakeup source on some devices. Especially on some of the am62* SoCs pins, connected to m_can in the mcu, can be used to wakeup the SoC. The wakeup-source property defines on which devices m_can can be used for wakeup. The pins associated with m_can have to have a special configuration to be able to wakeup the SoC. This configuration is described in the wakeup pinctrl state while the default state describes the default configuration. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Markus Schneider-Pargmann --- .../devicetree/bindings/net/can/bosch,m_can.yaml | 18 ++++++++++++++= ++++ 1 file changed, 18 insertions(+) diff --git a/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml b/D= ocumentation/devicetree/bindings/net/can/bosch,m_can.yaml index c4887522e8fe97c3947357b4dbd4ecf20ee8100a..0c1f9fa7371897d45539ead49c9= d290fb4966f30 100644 --- a/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml +++ b/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml @@ -106,6 +106,22 @@ properties: maximum: 32 minItems: 1 =20 + pinctrl-0: + description: Default pinctrl state + + pinctrl-1: + description: Wakeup pinctrl state + + pinctrl-names: + description: + When present should contain at least "default" describing the defaul= t pin + states. The second state called "wakeup" describes the pins in their + wakeup configuration required to exit sleep states. + minItems: 1 + items: + - const: default + - const: wakeup + power-domains: description: Power domain provider node and an args specifier containing @@ -122,6 +138,8 @@ properties: minItems: 1 maxItems: 2 =20 + wakeup-source: true + required: - compatible - reg --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-lf1-f52.google.com (mail-lf1-f52.google.com [209.85.167.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AE72515C145 for ; Tue, 15 Oct 2024 19:17:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019838; cv=none; b=gHlwRmz7TMNPT4860zfWqBoA3gnlBmiQHmmppDdT9CeesyQPLmHNgH4jqgam2aA8co1c3dwDjs9IOsL9HKf9KySFrkoF0waD2c19NReWbh8P3ojwUqFWcwRL9Zp3L8PSAFGXJALLKqe41L72o2D/uScQtVOuIP1kKTunmsNXOFU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019838; c=relaxed/simple; bh=UPDN5Sq6sr7oOOH4G9BvBLb/9GgPBe4IrDFtGwTay8A=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ImXynqYXOpWLqTFBAwAjJwugLuwirWXFyY0HWkJb8a2ShKF3+bx3F7KBpec3gJ41MNkHCFiYBFNBWzabR3FgWdD/fHBZYq3Tn2OAOFXYafkygoehjQAa+DUH25Cx/Nw0eiyk0V2pFO0Oor1ovNeRyE1p8Fl9rnqqp/qom51cZ+E= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=o02LR9nx; arc=none smtp.client-ip=209.85.167.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="o02LR9nx" Received: by mail-lf1-f52.google.com with SMTP id 2adb3069b0e04-539f1292a9bso3397884e87.2 for ; Tue, 15 Oct 2024 12:17:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019832; x=1729624632; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=saDUfDEJR0b1bnX4tkk4rHbVAroR4qkyv+y1+fjCTpM=; b=o02LR9nx3ANPw+3/leRzpqYGzyC7gIV/cbstbu0ddqnNo6ftVgmTrVAPBD4mKpcPJP ieXHNPoTvV2ceO/qbeRoCOBrEm+QjLLkOeoDdP2sJn8wh2xmiORFc/LOgA9bOzRUzJQG JxCuM/hf6aGQAPaKk66zDMsISwGz4ixcdD6hXXCLThl/p/y+SVliTca8QTe/hGHMHVFg mgu9U2N5Ua2LvE0ld243P6W1g3SzS2RL9h+qXPavAlHnWxEe9x+j+BYOWnRT/1fklhNz 35cms12r2VqKPo5Kus08wWFwiycdp0HO4xaD4f7S83CTMEqBWV8dDj/xwLuemZcC4Hhp x5tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019832; x=1729624632; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=saDUfDEJR0b1bnX4tkk4rHbVAroR4qkyv+y1+fjCTpM=; b=dI2v4mQ8eOJG72YNaZJv0IfAzL55f19zXlJFxJVxZyMPbePp1v2gNIISmbm4nM70dH HgxDpeAX+fgsUVFx2HRGTnA1G6TpxdM2o85BNer+PashwNCfMp+g4856kk0La9r8lIbk AA0/jYcqEO1t0KjN+U9oV253zf995YLsWRnvmt0oSuqxae8cYJE/OBaHFUSAN8UJSxoJ oO33Ub3EWLVP7d31JCik39/m3ewFA/cyfuBKofke0IuM47dKY/im//neC12S0IFMU/Kt FY/XIJrJZrq5/uDP5O4CRVO5MGkXXZnWl6U4XZLefzjPCYB9zSVmO/a+MQfc9yXbMo5C 2+7g== X-Forwarded-Encrypted: i=1; AJvYcCVEtnfUqEnXg1IaCmAbZtsC+t6m/3egNlMycA457X8E1qbCWQLGhOIVUBMAjPqkfopK3ARty4sAf9Yudks=@vger.kernel.org X-Gm-Message-State: AOJu0YyWMbGNQnT5fcAvaKgOxPgGWJPBquSLv39mNfKosMzJDlbzpdaF QzUJhVNxpQIUHCsIn8plUhxRZGSyIarEEMSmrHLojTuIxBCz8YFjNpIUjaFTAIk= X-Google-Smtp-Source: AGHT+IFxGivhAN/nSNOoLheyHq+ARNplWEmPyvbotn4tEsxOfN/CTNRV/WQq00xw7zNxKmVZkX8xEw== X-Received: by 2002:a05:6512:1599:b0:539:fd1b:baf5 with SMTP id 2adb3069b0e04-53a03f18d61mr957911e87.16.1729019831697; Tue, 15 Oct 2024 12:17:11 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a29844cc9sm100891566b.182.2024.10.15.12.17.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:11 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:15:56 +0200 Subject: [PATCH v4 2/9] dt-bindings: can: m_can: Add vio-supply Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-2-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann , Krzysztof Kozlowski X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1211; i=msp@baylibre.com; h=from:subject:message-id; bh=UPDN5Sq6sr7oOOH4G9BvBLb/9GgPBe4IrDFtGwTay8A=; b=kA0DAAgWJIy04tQVrj8ByyZiAGcOv4yj3tsKAl5GXHqokb05W6ep2N/lbn0I+W8qCDj1wuDdj Yh1BAAWCAAdFiEE3fCh7n4e16BYruJBJIy04tQVrj8FAmcOv4wACgkQJIy04tQVrj8loAEAg7v/ fmMlmA9duPbbiOawXOqpUc9t+28UBJWyEe/V8oUA/2oR68+3s4nCZte+s7g225dGBOOf9wokyJe BCw4WQjoO X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 The m_can unit can be integrated in different ways. For AM62 the unit is integrated in different parts of the system (MCU or Main domain) and can be powered by different external power sources. For example on am62-lp-sk mcu_mcan0 and mcu_mcan1 are powered through VDDSHV_CANUART by an external regulator. To be able to describe these relationships, add a vio-supply property to this binding. Acked-by: Krzysztof Kozlowski Signed-off-by: Markus Schneider-Pargmann --- Documentation/devicetree/bindings/net/can/bosch,m_can.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml b/D= ocumentation/devicetree/bindings/net/can/bosch,m_can.yaml index 0c1f9fa7371897d45539ead49c9d290fb4966f30..aac2add319e240f4f561b755f41= bf267b807ebcd 100644 --- a/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml +++ b/Documentation/devicetree/bindings/net/can/bosch,m_can.yaml @@ -140,6 +140,10 @@ properties: =20 wakeup-source: true =20 + vio-supply: + description: + Reference to the main power supply of the unit. + required: - compatible - reg --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ej1-f52.google.com (mail-ej1-f52.google.com [209.85.218.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D03041F583C for ; Tue, 15 Oct 2024 19:17:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019836; cv=none; b=YnRROfEi9VpYzDJMk6VESJ5wKRnDLo3bTbDsc5g32gtM2vfbg/EZzmPDn8hYSy4GriYL1cc0OCxe8dqY7mIbRJ3f7BSjxJdXPybeaYo2h8Wes0sILSVmMTKz3lYbbxU7aquXCY5WuE3FTwGheeOqOnU2JC7x6OZDWpiq0tFpFoI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019836; c=relaxed/simple; bh=u3MS8m9UeG/FKMz+2aOKCV8URfG29eAzix8kKH+yzxk=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=q+L4jLsPI/35F7SorZilT5Tf8bQIM3AUOUsWvL9m7dG/J+9oBrN6BV6MNsJ5C6jrMg5aDApBH2WR8hC4KLMbMBwP5fkv1dpu6nYNXKebgKmTThkjaRHuNGHHZHY5V5UjyaZSYgVV/1pZV9l0Og4sjeeaxkbth1b0bsrI0LHSnzU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=aRx+WeMN; arc=none smtp.client-ip=209.85.218.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="aRx+WeMN" Received: by mail-ej1-f52.google.com with SMTP id a640c23a62f3a-a99ffeea60bso437006166b.3 for ; Tue, 15 Oct 2024 12:17:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019833; x=1729624633; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=mWNsNiv/VcA8vMctiIZy19xLDs/iPmWut03+H1meriQ=; b=aRx+WeMNDcw4oUMj2yecYMyn8GuQMs1T05uOVYxNyL5CYOAilZtw600Q8cwMBRrMSn SdjQqeg+QAKJXbVy/YjiFMod7a+3GMYc54YGCsdHFwiRg3Iyhp8UL0yDFdzWwsy242p6 Spz9PmXvR4RI8fM18I1K/4/04vmkGyn6jGWwSysdBt6gL4FhjRRfVbl2ImHsf9yWdPrv FGS62aCUKiYFlm7lTujED/4YXHHe7WXATmzHdpYZIL85y515v+AZSoHmWb7iHd2aElEu 2wElNhXzqYygd8oqFhYcDYhHqxc7QGReYdqcQZk7dh73x/RiT6AiisNiThWHN1nJwVmF 4Y7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019833; x=1729624633; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mWNsNiv/VcA8vMctiIZy19xLDs/iPmWut03+H1meriQ=; b=wm0iyVydeAj9DRAxRrGh67i8Gph2uoJ4nyeSidO9eWwQtt3clr3zTWW/b3holzcqzG svb+lFEa44Bfqc7HXlNPbf8Up28dzvqzCkB3ZpnRdvEPau6JT7Zi1MOV/92ukBHHEzcG tb5t69HHek/RMEBM1LZ4+MG8x4cPlUlVxlTdqJbqlFtRlV970XIT04AK/XF/5HnYgn0+ xWzz1WHrt3rGm815YpSCnwV0DVohL/KJi4HBMRh5+OaHFAZFEOFswZRCpTVLau+hOLKF 3+y+WD7ZDKri/vg2J8CS1bjg38s8z6ZL651/Z2XDLc7FnmylxiIWtl6mYwqE/bkXNaz0 mHWw== X-Forwarded-Encrypted: i=1; AJvYcCVAvt8qPQ8c4Bk89BwhdusfR8YePkN1mGWXTNbo7KyY50bxJIc3laHm797of5w+siF0CafvAcu6CrF3sWM=@vger.kernel.org X-Gm-Message-State: AOJu0Yw+T6LFSL1oUAVdh/t0Xe9YLtz7Ob8MSaoLETGoMPkyupi6MeeF JwTFO3RZlk8VIu7o/wDpaCnEk6FOQC/sl6rZxWY719/KJ/akDb9HsDlAt468R6U= X-Google-Smtp-Source: AGHT+IG6Wi1Y05CbHfGWTKc2Zvkf+SR2UYH5CumYtIzfZCX8f8wWHAG3iJhGVNaioMcvfL42erh2WA== X-Received: by 2002:a17:907:94d0:b0:a9a:e2b:170e with SMTP id a640c23a62f3a-a9a0e2b1ab5mr793919066b.10.1729019832936; Tue, 15 Oct 2024 12:17:12 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a29843374sm101011666b.157.2024.10.15.12.17.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:12 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:15:57 +0200 Subject: [PATCH v4 3/9] can: m_can: Map WoL to device_set_wakeup_enable Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-3-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=2797; i=msp@baylibre.com; h=from:subject:message-id; bh=u3MS8m9UeG/FKMz+2aOKCV8URfG29eAzix8kKH+yzxk=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59k90PPz83/zbxmZT0q8prg/tYjDLUb7E+uH+Ke9ZS Uq3Dhjc7ChlYRDjYJAVU2S5+2Hhuzq56wsi1j1yhJnDygQyhIGLUwAmIv+N4X980sdAKe+fenOi BPbcXe81x0oilP1I45oVa5WXOBxoP9/IyNDGrD/7x7TU6bdipAy7HDhEikS1Q0/v9ew/mdkS1qO nyQYA X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 In some devices the pins of the m_can module can act as a wakeup source. This patch helps do that by connecting the PHY_WAKE WoL option to device_set_wakeup_enable. By marking this device as being wakeup enabled, this setting can be used by platform code to decide which sleep or poweroff mode to use. Also this prepares the driver for the next patch in which the pinctrl settings are changed depending on the desired wakeup source. Signed-off-by: Markus Schneider-Pargmann Reviewed-by: Vincent Mailhol --- drivers/net/can/m_can/m_can.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index a978b960f1f1e1e8273216ff330ab789d0fd6d51..d427645a5b3baf7d0a648e3b008= d7d7de7f23374 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -2185,6 +2185,36 @@ static int m_can_set_coalesce(struct net_device *dev, return 0; } =20 +static void m_can_get_wol(struct net_device *dev, struct ethtool_wolinfo *= wol) +{ + struct m_can_classdev *cdev =3D netdev_priv(dev); + + wol->supported =3D device_can_wakeup(cdev->dev) ? WAKE_PHY : 0; + wol->wolopts =3D device_may_wakeup(cdev->dev) ? WAKE_PHY : 0; +} + +static int m_can_set_wol(struct net_device *dev, struct ethtool_wolinfo *w= ol) +{ + struct m_can_classdev *cdev =3D netdev_priv(dev); + bool wol_enable =3D !!(wol->wolopts & WAKE_PHY); + int ret; + + if ((wol->wolopts & WAKE_PHY) !=3D wol->wolopts) + return -EINVAL; + + if (wol_enable =3D=3D device_may_wakeup(cdev->dev)) + return 0; + + ret =3D device_set_wakeup_enable(cdev->dev, wol_enable); + if (ret) { + netdev_err(cdev->net, "Failed to set wakeup enable %pE\n", + ERR_PTR(ret)); + return ret; + } + + return 0; +} + static const struct ethtool_ops m_can_ethtool_ops_coalescing =3D { .supported_coalesce_params =3D ETHTOOL_COALESCE_RX_USECS_IRQ | ETHTOOL_COALESCE_RX_MAX_FRAMES_IRQ | @@ -2194,10 +2224,14 @@ static const struct ethtool_ops m_can_ethtool_ops_c= oalescing =3D { .get_ts_info =3D ethtool_op_get_ts_info, .get_coalesce =3D m_can_get_coalesce, .set_coalesce =3D m_can_set_coalesce, + .get_wol =3D m_can_get_wol, + .set_wol =3D m_can_set_wol, }; =20 static const struct ethtool_ops m_can_ethtool_ops =3D { .get_ts_info =3D ethtool_op_get_ts_info, + .get_wol =3D m_can_get_wol, + .set_wol =3D m_can_set_wol, }; =20 static int register_m_can_dev(struct m_can_classdev *cdev) @@ -2324,6 +2358,9 @@ struct m_can_classdev *m_can_class_allocate_dev(struc= t device *dev, goto out; } =20 + if (dev->of_node && of_property_read_bool(dev->of_node, "wakeup-source")) + device_set_wakeup_capable(dev, true); + /* Get TX FIFO size * Defines the total amount of echo buffers for loopback */ --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ej1-f51.google.com (mail-ej1-f51.google.com [209.85.218.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CD3F01F76AF for ; Tue, 15 Oct 2024 19:17:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019838; cv=none; b=o4Q1Qqzxj6OnZlsjDcnnJcf8pLqkTaBdV0OtBkMl/ISNyTUJvoeXihGEd5Hh/rcabVmF5fHNzf2ozyKmTvvdOBSOiXL5YnX1cFmyV6b5/PGa+Q5l9Q9gwuGr+rkqj+8B/Rpto9NoN2yD0MQevXwXaaVif/0Xg6bjEw2rev2tfYA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019838; c=relaxed/simple; bh=FuSyoKzeygeLVHKVCKFUjItYDNK1CDXLTHh7H2UiD20=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=btH49VAvUMjD4HpvTLoedjS2S6EyUXojJAL7jDG+4wZXqa87BEOhC8N9wKao5hyu7p7vAkZg8LK4cmqDf2n2PJL3XpdfhX3Ol4am2ZnRX4NTo4wVjyCYkCNBegIziQ8H9jUkLCIdQ0Ey9iiiTz4a3S+CRRnPRWvO+Y/0mlAmOBY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=juhgP7ay; arc=none smtp.client-ip=209.85.218.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="juhgP7ay" Received: by mail-ej1-f51.google.com with SMTP id a640c23a62f3a-a9a0474e70eso454670366b.0 for ; Tue, 15 Oct 2024 12:17:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019834; x=1729624634; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=I+gZxIafqFrR6BMcHIhEjszPUzk8N9qpO7jS8LguSsI=; b=juhgP7ayi+LvA9yf0QMl8vCElhNfhgE+RsR56GzWQDqX3zJhpuzpaI3DWwTzZ3P5Ab uquwk+sENmZDyDHynds7wiEiII7JsskWwuboiH0eJcPrvsKi5CejsAKZNg+BKSD4YQwM jjBIZyy0FyCBapLvQ/eOYsu5LT0ANr/tNoeiBovWdhk4cdn1UGHGPBrug5Y6FqdS3xpB FnqFygrbHrIBCYN8s/Twh3eFgJgeoz4up26A0xO/n9h+5CbBDliHVft0TYpgrv1FCsdT YKrMbXrvXuv+Ak3vx3wUF2h3cZjxXe16AxB5V7lsGr98g5h0d1gswwZJwPfcBKjHuZmN Eobg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019834; x=1729624634; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=I+gZxIafqFrR6BMcHIhEjszPUzk8N9qpO7jS8LguSsI=; b=cLRzGYGyiXCkmk9Az3pcm5n34Cofh2EnCYWewA9n4cr74nDDGuRI3URNaeS+T8G5h4 6ggqGBjTa0knh7MacwunMhyrAjGmr6Mtx7zTa+3sdoK9n0tLRSRBeOpA0uu4IOqtx0UM TuXdo1rYyXebFgWRHDYowjTCClBlfPSji76I8WQhXrwLB6LznQLcIFCBMMrGwAQ2ilwQ Cc8mJH/4XHL0drcIOV+xwrlu0xCRn7Yo+K+IbK10o+I6FeL5UrsC6k5xc3zmgSXaXdMJ fankJtlbCSl7/JDShlRjWBdd5sbNnzub249dMXqYHaPKxFvPW9SjOYFyUr4XzrYWffEo 4ktQ== X-Forwarded-Encrypted: i=1; AJvYcCVxAxajAWrekHIvEF+vBv6M/2Hzzf1x4mV+t8aFh/Z5Gfdl6et9olIy07ZEpUCMotAqfDa/KCXaLQNjtPM=@vger.kernel.org X-Gm-Message-State: AOJu0YyioCO9KsBiD9eBPKc5Y9lR1d8tcpVxnzqPrMgjhxce1m8HpJYi TpJVXJKReMkBAopkvwW2WNhDWvJ28UtgpQdiZ1RYAoGsGMh4mUmjXRu20IpVLDY= X-Google-Smtp-Source: AGHT+IEnWhyoMdkPWKAnqSZfQ5E35xloBUwyytezjQk7zjPCXojeRmRve/u2bGJ3yuGwNR720ej3zA== X-Received: by 2002:a17:907:f1c7:b0:a99:8a0e:8710 with SMTP id a640c23a62f3a-a99e3b5b167mr1064453866b.14.1729019834109; Tue, 15 Oct 2024 12:17:14 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a2988c57asm101052866b.204.2024.10.15.12.17.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:13 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:15:58 +0200 Subject: [PATCH v4 4/9] can: m_can: Return ERR_PTR on error in allocation Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-4-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3520; i=msp@baylibre.com; h=from:subject:message-id; bh=FuSyoKzeygeLVHKVCKFUjItYDNK1CDXLTHh7H2UiD20=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59k/z2Lj1No/cl7I9t1MUPx1QXZx7ecckPVFvB4mmI 2vai37N7ShlYRDjYJAVU2S5+2Hhuzq56wsi1j1yhJnDygQyhIGLUwAmsnEtI8MuIZcVy569Tdhl d/vE54mpLC8EmrNF9zk++LzZc6pH01NORoZbyw0ily0ubKg1lLGYPcPCO03OcfI1x4lTduVd3MI WEsUIAA== X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 We have more detailed error values available, return them in the core driver and the calling drivers to return proper errors to callers. Reviewed-by: Vincent Mailhol Signed-off-by: Markus Schneider-Pargmann --- drivers/net/can/m_can/m_can.c | 6 +++--- drivers/net/can/m_can/m_can_pci.c | 4 ++-- drivers/net/can/m_can/m_can_platform.c | 4 ++-- drivers/net/can/m_can/tcan4x5x-core.c | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index d427645a5b3baf7d0a648e3b008d7d7de7f23374..5a4e0ad07e9ecc82de5f1f60670= 7f3380d3679fc 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -2355,7 +2355,7 @@ struct m_can_classdev *m_can_class_allocate_dev(struc= t device *dev, sizeof(mram_config_vals) / 4); if (ret) { dev_err(dev, "Could not get Message RAM configuration."); - goto out; + return ERR_PTR(ret); } =20 if (dev->of_node && of_property_read_bool(dev->of_node, "wakeup-source")) @@ -2370,7 +2370,7 @@ struct m_can_classdev *m_can_class_allocate_dev(struc= t device *dev, net_dev =3D alloc_candev(sizeof_priv, tx_fifo_size); if (!net_dev) { dev_err(dev, "Failed to allocate CAN device"); - goto out; + return ERR_PTR(-ENOMEM); } =20 class_dev =3D netdev_priv(net_dev); @@ -2379,7 +2379,7 @@ struct m_can_classdev *m_can_class_allocate_dev(struc= t device *dev, SET_NETDEV_DEV(net_dev, dev); =20 m_can_of_parse_mram(class_dev, mram_config_vals); -out: + return class_dev; } EXPORT_SYMBOL_GPL(m_can_class_allocate_dev); diff --git a/drivers/net/can/m_can/m_can_pci.c b/drivers/net/can/m_can/m_ca= n_pci.c index d72fe771dfc7aa768c728f817e67a87b49fd9974..05a01dfdbfbf18b74f796d2efc7= 5e2be5cbb75ed 100644 --- a/drivers/net/can/m_can/m_can_pci.c +++ b/drivers/net/can/m_can/m_can_pci.c @@ -111,8 +111,8 @@ static int m_can_pci_probe(struct pci_dev *pci, const s= truct pci_device_id *id) =20 mcan_class =3D m_can_class_allocate_dev(&pci->dev, sizeof(struct m_can_pci_priv)); - if (!mcan_class) - return -ENOMEM; + if (IS_ERR(mcan_class)) + return PTR_ERR(mcan_class); =20 priv =3D cdev_to_priv(mcan_class); =20 diff --git a/drivers/net/can/m_can/m_can_platform.c b/drivers/net/can/m_can= /m_can_platform.c index b832566efda042929486578fad1879c7ad4a0cff..40bd10f71f0e2fab847c40c5bd5= f7d85d3d46712 100644 --- a/drivers/net/can/m_can/m_can_platform.c +++ b/drivers/net/can/m_can/m_can_platform.c @@ -87,8 +87,8 @@ static int m_can_plat_probe(struct platform_device *pdev) =20 mcan_class =3D m_can_class_allocate_dev(&pdev->dev, sizeof(struct m_can_plat_priv)); - if (!mcan_class) - return -ENOMEM; + if (IS_ERR(mcan_class)) + return PTR_ERR(mcan_class); =20 priv =3D cdev_to_priv(mcan_class); =20 diff --git a/drivers/net/can/m_can/tcan4x5x-core.c b/drivers/net/can/m_can/= tcan4x5x-core.c index 2f73bf3abad889c222f15c39a3d43de1a1cf5fbb..4c40b444727585b30df33a897c3= 98e35e7592fb2 100644 --- a/drivers/net/can/m_can/tcan4x5x-core.c +++ b/drivers/net/can/m_can/tcan4x5x-core.c @@ -375,8 +375,8 @@ static int tcan4x5x_can_probe(struct spi_device *spi) =20 mcan_class =3D m_can_class_allocate_dev(&spi->dev, sizeof(struct tcan4x5x_priv)); - if (!mcan_class) - return -ENOMEM; + if (IS_ERR(mcan_class)) + return PTR_ERR(mcan_class); =20 ret =3D m_can_check_mram_cfg(mcan_class, TCAN4X5X_MRAM_SIZE); if (ret) --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 209CF189B8A for ; Tue, 15 Oct 2024 19:17:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.49 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019840; cv=none; b=SEz5hkAffj1cCM0MiS2rTcwcFN1IQ++oVmVBGHwQKquZXxVaKTdjJAu9R94T/K3+2qC0lBPg7YCPdD/khQNv654VcgkFjMZISLWSrqQS++i/AQ3Kp6r++d5HPSHWVaGb/DmxDdG4rBD3izK//iAiQ2/nNTFd/Y11qSoms3q36HI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019840; c=relaxed/simple; bh=fXagSgDKvwKb5T6QGKzoWAYbWw5MKKnGO7kvv5dC+zw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=I14TBQY8AhuUObMCF9cu1IKBETtdjfSaZTwWaFJQhO+ii1NoHiQMaDsdR0dpLKI/TimAKkB85I5LB6T9xDV4YYx5xO05pODiIlU8bj1Q6UCyf6d3ttGoul3Xx/CM0Y+9d0YOuWzwDMxKuAh9C1C5ynqhjkS+o9JDfNE9qUvHjeM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=g8MztsLb; arc=none smtp.client-ip=209.85.208.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="g8MztsLb" Received: by mail-ed1-f49.google.com with SMTP id 4fb4d7f45d1cf-5c97c7852e8so3696256a12.1 for ; Tue, 15 Oct 2024 12:17:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019835; x=1729624635; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=C53L7ElLnJx+g4UjgYE4Yk8Jb0cDN7FkWpfutP4xQkE=; b=g8MztsLbbVe2vbXc3HI9g111NcVnftyTdIDoktkJf6sxtGJKEdRxSzPvJMU9OJe682 k2srQbja1hjXcKdIjF/r7yzVJAIxKX3EivNIQDxOCEoU8d/xASrQ9WSgQqkpyhE/wHjf t/OZSpKpNJAUGbvpn4SDak8IEn+yD8vaGxw0npgqeDsdcb5VJfybMVXUhJ3b3LYQ1jZ0 asPIt3zpRhJo6Hi6FaEOkn9zhq4SAibfKuHwNxhMhEwu6fxK8QbrXxSLjMU3pDdiHM/x jpEYj+zcG0YrsSjSMK6h6SYUufvHMie5hGAgkVW6SVJ03MiqgqbGEbT06+YuEUs1US0g Pe8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019835; x=1729624635; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=C53L7ElLnJx+g4UjgYE4Yk8Jb0cDN7FkWpfutP4xQkE=; b=NFG7wlQXDTPly6uDke/xzmiCMimhO3/aZ9PLEpx5kAdjus2bkIuj20GXE8G/66lIXa cbHqfptbrtzJA2tu0Yc8i9+RZJNlbANgRpXBrD2kIRZsb54siBB7GP4I6YRLwwyi3nFX EgorOWIJaS1JUENf7+jRhvwL09nt8c7fQhjGAipPZZNFRsmIvVsWsZJVKwe6E0+VK28P 0qQ3B350eOSM6za/Nexi5fBP6JAOgn5zK8ycmxfeDLfKcRw2pTdWFh/Z9UKHmwIAFRar o3IlLMmw2az1sR2cIULjubLNnwg11ZAfo2ouypvai3cEh9RWf9scLSpoPUcZoM4ph0Ft DVWw== X-Forwarded-Encrypted: i=1; AJvYcCW1klsk8/j9Aiy2bFQvXwx4S5JSljCGM+OB69pmNOUIwUlkm5ulJbCVWwTRAG76icC+VSeI4l9/x6OemU4=@vger.kernel.org X-Gm-Message-State: AOJu0YzmSV+gEH0iQeJOjfCpL2tXzxsb8HiFYZmPEQy+3UmE6jFI+B1W Y20SgTjtLOTh93h0d2mDA0JZnS9XDai372/YMEvO21MEj5FjLZCKPL8Y8oQkezE= X-Google-Smtp-Source: AGHT+IFuNaXJ/r/nqGOo1Icj0J/5EWknD2G800st6YUHsrMWW7mRsRlVQykeajKpoYEWh9kT1ftaMA== X-Received: by 2002:a05:6402:5191:b0:5c9:5e43:9480 with SMTP id 4fb4d7f45d1cf-5c95e43f157mr8602638a12.7.1729019835369; Tue, 15 Oct 2024 12:17:15 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5c98d5298d1sm990283a12.57.2024.10.15.12.17.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:14 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:15:59 +0200 Subject: [PATCH v4 5/9] can: m_can: Support pinctrl wakeup state Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-5-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=4027; i=msp@baylibre.com; h=from:subject:message-id; bh=fXagSgDKvwKb5T6QGKzoWAYbWw5MKKnGO7kvv5dC+zw=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59s9uW8v09/SRimWqRdrZTa8f+wvx3hdxjb40ibtyW kPi0VCzjlIWBjEOBlkxRZa7Hxa+q5O7viBi3SNHmDmsTCBDGLg4BWAiTz8yMmyomvCWXXrysZVi HZXeE9ms2F33pGXcrYjQbDRR2r9z4RFGho4nHXcD3TPPxG17WRX4rudRD3OK5KsTb6+y+FfkTem I5AAA X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 am62 requires a wakeup flag being set in pinctrl when mcan pins acts as a wakeup source. Add support to select the wakeup state if WOL is enabled. Signed-off-by: Markus Schneider-Pargmann Reviewed-by: Vincent Mailhol --- drivers/net/can/m_can/m_can.c | 68 +++++++++++++++++++++++++++++++++++++++= ++++ drivers/net/can/m_can/m_can.h | 4 +++ 2 files changed, 72 insertions(+) diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index 5a4e0ad07e9ecc82de5f1f606707f3380d3679fc..c539375005f71c88fd1f7d1a885= ce890ce0e9327 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -2196,6 +2196,7 @@ static void m_can_get_wol(struct net_device *dev, str= uct ethtool_wolinfo *wol) static int m_can_set_wol(struct net_device *dev, struct ethtool_wolinfo *w= ol) { struct m_can_classdev *cdev =3D netdev_priv(dev); + struct pinctrl_state *new_pinctrl_state =3D NULL; bool wol_enable =3D !!(wol->wolopts & WAKE_PHY); int ret; =20 @@ -2212,7 +2213,28 @@ static int m_can_set_wol(struct net_device *dev, str= uct ethtool_wolinfo *wol) return ret; } =20 + if (wol_enable) + new_pinctrl_state =3D cdev->pinctrl_state_wakeup; + else + new_pinctrl_state =3D cdev->pinctrl_state_default; + + if (IS_ERR_OR_NULL(new_pinctrl_state)) + return 0; + + ret =3D pinctrl_select_state(cdev->pinctrl, new_pinctrl_state); + if (ret) { + netdev_err(cdev->net, "Failed to select pinctrl state %pE\n", + ERR_PTR(ret)); + goto err_wakeup_enable; + } + return 0; + +err_wakeup_enable: + /* Revert wakeup enable */ + device_set_wakeup_enable(cdev->dev, !wol_enable); + + return ret; } =20 static const struct ethtool_ops m_can_ethtool_ops_coalescing =3D { @@ -2340,6 +2362,44 @@ int m_can_class_get_clocks(struct m_can_classdev *cd= ev) } EXPORT_SYMBOL_GPL(m_can_class_get_clocks); =20 +static int m_can_class_setup_optional_pinctrl(struct m_can_classdev *class= _dev) +{ + struct device *dev =3D class_dev->dev; + int ret; + + class_dev->pinctrl =3D devm_pinctrl_get(dev); + if (IS_ERR(class_dev->pinctrl)) { + ret =3D PTR_ERR(class_dev->pinctrl); + class_dev->pinctrl =3D NULL; + + if (ret =3D=3D -ENODEV) + return 0; + + return dev_err_probe(dev, ret, "Failed to get pinctrl\n"); + } + + class_dev->pinctrl_state_wakeup =3D + pinctrl_lookup_state(class_dev->pinctrl, "wakeup"); + if (IS_ERR(class_dev->pinctrl_state_wakeup)) { + ret =3D PTR_ERR(class_dev->pinctrl_state_wakeup); + class_dev->pinctrl_state_wakeup =3D NULL; + + if (ret =3D=3D -ENODEV) + return 0; + + return dev_err_probe(dev, ret, "Failed to lookup pinctrl wakeup state\n"= ); + } + + class_dev->pinctrl_state_default =3D + pinctrl_lookup_state(class_dev->pinctrl, "default"); + if (IS_ERR(class_dev->pinctrl_state_default)) { + ret =3D PTR_ERR(class_dev->pinctrl_state_default); + return dev_err_probe(dev, ret, "Failed to lookup pinctrl default state\n= "); + } + + return 0; +} + struct m_can_classdev *m_can_class_allocate_dev(struct device *dev, int sizeof_priv) { @@ -2380,7 +2440,15 @@ struct m_can_classdev *m_can_class_allocate_dev(stru= ct device *dev, =20 m_can_of_parse_mram(class_dev, mram_config_vals); =20 + ret =3D m_can_class_setup_optional_pinctrl(class_dev); + if (ret) + goto err_free_candev; + return class_dev; + +err_free_candev: + free_candev(net_dev); + return ERR_PTR(ret); } EXPORT_SYMBOL_GPL(m_can_class_allocate_dev); =20 diff --git a/drivers/net/can/m_can/m_can.h b/drivers/net/can/m_can/m_can.h index 92b2bd8628e6b31370f4accbc2e28f3b2257a71d..b75b0dd6ccc93973d0891daac07= c92b61f81dc2a 100644 --- a/drivers/net/can/m_can/m_can.h +++ b/drivers/net/can/m_can/m_can.h @@ -126,6 +126,10 @@ struct m_can_classdev { struct mram_cfg mcfg[MRAM_CFG_NUM]; =20 struct hrtimer hrtimer; + + struct pinctrl *pinctrl; + struct pinctrl_state *pinctrl_state_default; + struct pinctrl_state *pinctrl_state_wakeup; }; =20 struct m_can_classdev *m_can_class_allocate_dev(struct device *dev, int si= zeof_priv); --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-lj1-f176.google.com (mail-lj1-f176.google.com [209.85.208.176]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 78B2A1FBF43 for ; Tue, 15 Oct 2024 19:17:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.176 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019840; cv=none; b=eIxgVdfHThO2eheEcLUFo842pwg+aqPacoykD6F1J4oyf6anmR/bcfVm1WXyLE4FGZlCkmjCt5ssrJpu/QvFb/VQPK7veRLtYqHEMwX0ECvGLSC21H7o7CsHSZTalL+Xt4kGsFdpEdL1cdrF7W7AfaUfMUJd0OapGUgTX3OwNBk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019840; c=relaxed/simple; bh=aipUUq+7RrB1fQczjwGFQJsXFUnND3UwiWP5TZKO64w=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=mld8UB/r7uAmxkgJ3qRJ2kWh7mzU425R2dFos65E2jw8CIdDQHfIHMAuZszLNib5HsibJWqT52Zj/e7y8yWK5iRYf4rSa/EnxSsV7MKyQzXp41CBacwGbXukRcYNbA2SXKK1jD2YfuGc/a7bz7oaSGIj0lDm2ei0xrJMvOKdE7g= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=xOVqTCen; arc=none smtp.client-ip=209.85.208.176 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="xOVqTCen" Received: by mail-lj1-f176.google.com with SMTP id 38308e7fff4ca-2fb587d0436so19117611fa.2 for ; Tue, 15 Oct 2024 12:17:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019837; x=1729624637; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=sjKPLiEdokQkg97Y4Rb67l893kRgrHE7+ULSYL6zJKs=; b=xOVqTCenmIJTaAmWEqUZFj30FSLRy9LU/fiU1SyDuIpBkv9vDstdB8qspfAjO7TncI /Lp4zd4Hgt6nIp+MuPptwGr54JSrrccKnjuI20BjkuTwMTblcmqHdfvTR+eziZKayFYs fzaK0Y/j/pPHbro4wZ48B+iRuQz8lSRtwLzkTtgnb5PAji+oqNsSJ6V/oE5thC5fKR7n ruo8vW3y0XGekPQsjKi9q8AmhNRISPamgt1eVlfcXAM/zGIglQhshmRo+vLYDkZQrdTv fdK0nYf108A5dYAup7tqiGv3qo6No5FWWidZjc03XrfUpnLh3TkFQb9pNbxMBr4/nNrI ipDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019837; x=1729624637; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=sjKPLiEdokQkg97Y4Rb67l893kRgrHE7+ULSYL6zJKs=; b=na1iiGseGf4YYb24rixHEGyc3FMRumwfojixtWhqp1cnJi/y3WTV/nBvC6sq7pkhy/ 5cDc/hAfeD9s95xHx2Xpmv1ithvdrIhhzfZYHZe8KDB39XS4aEbBHZOZVaoEhubPCR8a f/TOKbfpZsFEnEy49amH/XF++T53Xvj+wGREUAzdRkA0B/OoP8hwViy4fR4EnWcb3tfJ pgwtSvIbgtVcFcV0bfKebPUIj2NAysJtrgmoLgNNJVMGizTpk+jWfkKnD7d079iI54WD 7iBmZLh9QXnRIkb0NPDRcBUqtAvzDQlIpf/nd6JNbyP1YJDI9kBWqNc6lmCOI0GKbrhO gQ6Q== X-Forwarded-Encrypted: i=1; AJvYcCUyavSBbgrJznKrEYO7M6SBbnuKaKlisQ9dgVxzsNvEScRhe8+Ns1Hoi81FILMM/UXfaSIUt0IIWGeKxBY=@vger.kernel.org X-Gm-Message-State: AOJu0Yx8jBrTuMBx20YlB/cK8tSJIM4b/JZ439kdvTlj/hoCqM/yWhD5 UDbDtaUHLK7bpAZxxQLZmEpglzWIUv4E0+npmupDK+WE21crWu9BrSw/e2jmXdE= X-Google-Smtp-Source: AGHT+IE4dzRsD/tCQ28U43nJXbo8BVQgpvc+e/8APYlr/mwBjZLsFjDakC3/JIU6v1rQg0lg4s5rnQ== X-Received: by 2002:a2e:b8ce:0:b0:2fb:c20:dbc3 with SMTP id 38308e7fff4ca-2fb3f2edde8mr59233971fa.39.1729019836565; Tue, 15 Oct 2024 12:17:16 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5c98d779975sm971515a12.67.2024.10.15.12.17.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:16 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:16:00 +0200 Subject: [PATCH v4 6/9] can: m_can: Add use of optional regulator Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-6-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1254; i=msp@baylibre.com; h=from:subject:message-id; bh=aipUUq+7RrB1fQczjwGFQJsXFUnND3UwiWP5TZKO64w=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59s/XqnFdKfDRbN+T+WsKHVybDbOyYt1kjex0p2ZPP 8fbcdSko5SFQYyDQVZMkeXuh4Xv6uSuL4hY98gRZg4rE8gQBi5OAZiI3W1GhjWPb03bLCHc+rVj 3ZH/zMcOcPNpBHzacP4tp8yJfSt1F2xnZHj2dff7aQv9JK24TzXfzy/8Wc/B2PdyzTW3nvPTvY3 Cm7gA X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 Add support to use a regulator for the core. This is optional and used to register the dependency on the regulator. Reviewed-by: Vincent Mailhol Signed-off-by: Markus Schneider-Pargmann --- drivers/net/can/m_can/m_can.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index c539375005f71c88fd1f7d1a885ce890ce0e9327..274fdcae49c31d4792b81cdc065= 821206d3cb206 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -23,6 +23,7 @@ #include #include #include +#include =20 #include "m_can.h" =20 @@ -2421,6 +2422,11 @@ struct m_can_classdev *m_can_class_allocate_dev(stru= ct device *dev, if (dev->of_node && of_property_read_bool(dev->of_node, "wakeup-source")) device_set_wakeup_capable(dev, true); =20 + ret =3D devm_regulator_get_enable_optional(dev, "vio"); + if (ret) + return ERR_PTR( + dev_err_probe(dev, ret, "Failed to get or enable optional regulator\n")= ); + /* Get TX FIFO size * Defines the total amount of echo buffers for loopback */ --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ed1-f41.google.com (mail-ed1-f41.google.com [209.85.208.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 687861FBF5A for ; Tue, 15 Oct 2024 19:17:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019841; cv=none; b=DQVXCg8UebQRpck2CEMIXXL56B21aPAn8fpnlEWC9RSoDIyUAmOWeMnpX1gA9kfMg1tfdtffcIesYudz+i4xijbIZPxYKDUYwkDZviOAQdHTBnmLxrOiqGKJ5SlHu5AnJq5ctBeRR/BcYs1Z99Q16vb8WvBFe1YNS5hHNmQ1Goo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019841; c=relaxed/simple; bh=L5jePk++a0uY91JQrASnpEj/bjSiMyJjUq1CjjPGGl0=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=gNazzHAG4G4S5hLaQmH5Bk8YrxAuo/HjmE16Xcb9h7f1cCrShfgBWuJ82Ppl/2Y+odUwGybAZepZ+UFa9TMPpgJDhS1iyovDIQy0Nw1hRkja0dKyfFO3G30V540ySdOvte6kpmumJ1TWU/W52mSErMd3Dc3ScKHp6vGTzU/DqJk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=KO6S99S9; arc=none smtp.client-ip=209.85.208.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="KO6S99S9" Received: by mail-ed1-f41.google.com with SMTP id 4fb4d7f45d1cf-5c9150f9ed4so7380967a12.0 for ; Tue, 15 Oct 2024 12:17:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019838; x=1729624638; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=81ZVnQPK5cdOXNd0U587x7C4r0h4m8ObdC4H2ODABA8=; b=KO6S99S9vvJC6jPwferK4Qdwsv3qaOE13nUZWqwJ0ZcbEsoxDEamDK7YKwSHV5Hm5z zwzHV0HqOIKYGNnPQyHu9j1XRfruafAwsFOlb76Nty6agI1sVXPbljeC8yOmT7R3u+xs PRuEyMVFZKIk9ZJPDX7gnuhYYlUsv8h1BsVSuNAtUxB7pm9bbiBA2Y6TA5uAd5S7S1d2 eNVfpyHLviBQi+yvZtPuAeWlRVzdIAS3ZCdxlv0xPPiKoxTOZyN7/c9+ZR2ITAIPkoW+ dG9L7zxK6xB1oS7MHgkA3KwQdjbz7VLZIeWp3A9/mTJyBN6QcLqLZxUVavgbzc73RHqO Tp4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019838; x=1729624638; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=81ZVnQPK5cdOXNd0U587x7C4r0h4m8ObdC4H2ODABA8=; b=GYy86XGnI984BN0lQyUXj9Ld0D7UJM4LZxvBCXHQFJP5KePsmrTJKzr2unmgX3dECT mROoUojveHNynmPfPK7Ga8Oeh/+4fwzu7AIF2bLlHXT9eL75o6X07HFxKIhjN5JXMHY4 sIQRLoLbydBcbUU+Cx7HquNr+4qL2jUnsE3+F6MpcT+xg7VAIuilWXLBvB8lybspCXhi IR29dW0U5oEMhFlkJn0L1OAKceMlwXyYf+J97jmbUorXn4RGXLObP0XMNL2Q5ZPViD9/ coK5/SK68eRokv4X+5RN4B1+8mdjZaQS3ttRK5R4p6NNZvCO1xXsrrY2KmtRIfkE15qg cVCQ== X-Forwarded-Encrypted: i=1; AJvYcCX2D4XQt2dze8ONtEMAyF3wqbfkP9ycCJtx3c2eK7v/T4noqPyXcVpZhFTjG4pEkeH0okS4iiXSJB5+5Xg=@vger.kernel.org X-Gm-Message-State: AOJu0Yy4INbe8v7vAIIbs1jFaINZoKxpuaAAcrr91ykvH5euzfRq/+pE vnPA+hiy8YYPQafFXVCTMYA7yWwX0YmeMyaAIyX1EmRJrwwNlSUb1SwwWMX3mDs= X-Google-Smtp-Source: AGHT+IFe6y5YxcAp7iE8drp6DyY0gA3+wgMZd7L0bgY5EMYWR88rCbdnKDAk49FEAypBphut0IJ6yA== X-Received: by 2002:a17:907:d2e7:b0:a99:ffef:aec5 with SMTP id a640c23a62f3a-a9a34d6e9aamr112640966b.23.1729019837837; Tue, 15 Oct 2024 12:17:17 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a29719196sm102080566b.33.2024.10.15.12.17.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:17 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:16:01 +0200 Subject: [PATCH v4 7/9] arm64: dts: ti: k3-am62: Mark mcu_mcan0/1 as wakeup-source Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-7-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1023; i=msp@baylibre.com; h=from:subject:message-id; bh=L5jePk++a0uY91JQrASnpEj/bjSiMyJjUq1CjjPGGl0=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59i+ZPGmy1PW/eRuvPTjolT7riMnqP14vVzI8zrkwQ ZTN5MC9VR2lLAxiHAyyYoosdz8sfFcnd31BxLpHjjBzWJlAhjBwcQrARBYwMjIsYM/J0lA7kHP4 Q/++E0fME6Re9uxXntPq4Zd84HR8z+/vDP8Lzq/Z6PgoQWlP5tqAreWOy+cnel2cfj5mb2c653X Jl4XMAA== X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 mcu_mcan0 and mcu_mcan1 can be wakeup sources for the SoC. Mark them accordingly in the devicetree. Signed-off-by: Markus Schneider-Pargmann --- arch/arm64/boot/dts/ti/k3-am62-mcu.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-am62-mcu.dtsi b/arch/arm64/boot/dts/= ti/k3-am62-mcu.dtsi index bb43a411f59b281df476afcb1a71b988ca27f002..e22177b9dfecb541e99b0807f8b= 79e7b878b6514 100644 --- a/arch/arm64/boot/dts/ti/k3-am62-mcu.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62-mcu.dtsi @@ -160,6 +160,7 @@ mcu_mcan0: can@4e08000 { clocks =3D <&k3_clks 188 6>, <&k3_clks 188 1>; clock-names =3D "hclk", "cclk"; bosch,mram-cfg =3D <0x0 128 64 64 64 64 32 32>; + wakeup-source; status =3D "disabled"; }; =20 @@ -172,6 +173,7 @@ mcu_mcan1: can@4e18000 { clocks =3D <&k3_clks 189 6>, <&k3_clks 189 1>; clock-names =3D "hclk", "cclk"; bosch,mram-cfg =3D <0x0 128 64 64 64 64 32 32>; + wakeup-source; status =3D "disabled"; }; }; --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9B91C1B6CEA for ; Tue, 15 Oct 2024 19:17:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019842; cv=none; b=I3XSeL0v6FZPK/GlBCoLS/sFwwvrRx9hDRNrSxxmDUuUCTxPBsop+9pkvQbe0E+XKZh0j4KXPsHHbS8U/5By/PKjFJph2vH2AZf7MoR66NZ0CW25N1xVYF6ctVNTypPCQd+nst6FFsdb8oVo18RgGL3axx7vGtrCF41CbEdAPCo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019842; c=relaxed/simple; bh=lb40xLu/VXrpPNedn2QOJM+HYtvP+0chbzXXKOqoOlE=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Rn3buzFh4jwJHCN6errOxC0uoXyyT8ACVVRRZaily8mQGfig5ZKQk/59YbPkZUifhYrKcCYLjb10mnggpV6r4KWbp6OROVZJGNm+P45WAlhyyCf3t29c3A+Mkp+K27RKkTpMrJY2JIn7O6Nz3ODGL9m7on3L1uHCvbZPrxCb5Vw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=oqyNBxUJ; arc=none smtp.client-ip=209.85.208.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="oqyNBxUJ" Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-5c903f5bd0eso8704905a12.3 for ; Tue, 15 Oct 2024 12:17:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019839; x=1729624639; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=p570CyCpET4jQOMvqTRvBlj0hjjJLO72psUJRNLRpe8=; b=oqyNBxUJiVwQVjhd2+Ch3d+xtbIXFW/osPtkqkGtccsOjMtB3yJA0MzSknL9xwKVMf CCRhA6Y0hUIB9JxVKZtbmeTQBgG21/p6tzhB58S9jyNOhgxnguBVjdOtfq49DrL1Hgy6 pClpuZuFV/COeU8vsjBcJRHUV2gTAVzib7A4v/xvpFIiLtYoN3BGo6rE7OM1sM4DPjbs kONz9mJ9kzeBbC3ogBERG0hw2VZCt48kpWKLK7WXLVQi6gmHOZgsS5fYz5dkgwl8Xfpy bqEjWiSfU9IaI4ND03tsh97hTb1WZVTxILXx6sJAsxXQ3B+m0/I9DdKaPMnQpDk/7owg gv2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019839; x=1729624639; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=p570CyCpET4jQOMvqTRvBlj0hjjJLO72psUJRNLRpe8=; b=kGKIOX7e8P958L54rFELZl7HMyei6gvzpfmv9blKhZDFfbmmuP/CrG3wmRBc4+aWdW N/+JNXVYvRM0QC/6+UdHKoz0t3V4C1+RHS8KlVjKYo9jODKzb/qUCQZFKSmmPVVaxJGJ xF/ppt8MrJmB71YyhoToO1ZkkxG8aDR4dWAjiKO0cSjXKUlN7izvfSZfg/HmVftImjom BW7RgAJcAThGdTmd838fNKCZ2fWgieFy6fcY6HLYrDNrbPaycKHgqDAqdYuF4qQH6NNM olZknyXS4lRGBUcdkBOp/gF3IX42B1pAUipB5ctxmzg4U8PZGeQTnayFz16K7RP1BQf+ uOcA== X-Forwarded-Encrypted: i=1; AJvYcCUeKMblF2ByBmwvxsXpaMU4jzuuISbYYOBESzcX/haepRd/ez2IbySFq0l+3D47KLcLVnGMBzDYZEI/3Jo=@vger.kernel.org X-Gm-Message-State: AOJu0YzcnXiu/4YdyHoRy877Ky0Mv/2A7YocsM5KZVhUtcRp2hqtzF5m E6OTKN3Xwd1oAcrGfL4Ug7UZofLII7SLpW127Lej1Yy5hwYBzlTgbxMWf9AX/zQ= X-Google-Smtp-Source: AGHT+IFeN2E97a+E3jhI8sBljZvv6XC7mfzgwimmU3ry+3H1MazUngu2M9qkKbFXzssYTp7lbfxmBA== X-Received: by 2002:a17:907:9709:b0:a9a:4d1:460 with SMTP id a640c23a62f3a-a9a04d10662mr844482266b.63.1729019839017; Tue, 15 Oct 2024 12:17:19 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a29816bf8sm100951666b.101.2024.10.15.12.17.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:18 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:16:02 +0200 Subject: [PATCH v4 8/9] arm64: dts: ti: k3-am62a-mcu: Mark mcu_mcan0/1 as wakeup-source Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-8-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1028; i=msp@baylibre.com; h=from:subject:message-id; bh=lb40xLu/VXrpPNedn2QOJM+HYtvP+0chbzXXKOqoOlE=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59q94MX33ke3S9c4mE9jWHv1mP//Od4Gayds38yydZ v7npB6zXEcpC4MYB4OsmCLL3Q8L39XJXV8Qse6RI8wcViaQIQxcnAIwEZ6/jAzn9mxmt1lycNe9 2dWNL/cnhb/10NRZMPF0+CKGhFVXS82/MfyVreBkqimdrOu19NX5C99vFH+21DlW5Wcf7ew0qWJ RjDYzAA== X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 mcu_mcan0 and mcu_mcan1 can be wakeup sources for the SoC. Mark them accordingly in the devicetree. Signed-off-by: Markus Schneider-Pargmann --- arch/arm64/boot/dts/ti/k3-am62a-mcu.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-am62a-mcu.dtsi b/arch/arm64/boot/dts= /ti/k3-am62a-mcu.dtsi index 0469c766b769e46068f23e0073f951aa094c456f..06361cfd7a8ee6f2acf2d15e810= 6087dd0f38008 100644 --- a/arch/arm64/boot/dts/ti/k3-am62a-mcu.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62a-mcu.dtsi @@ -161,6 +161,7 @@ mcu_mcan0: can@4e08000 { clocks =3D <&k3_clks 188 6>, <&k3_clks 188 1>; clock-names =3D "hclk", "cclk"; bosch,mram-cfg =3D <0x0 128 64 64 64 64 32 32>; + wakeup-source; status =3D "disabled"; }; =20 @@ -173,6 +174,7 @@ mcu_mcan1: can@4e18000 { clocks =3D <&k3_clks 189 6>, <&k3_clks 189 1>; clock-names =3D "hclk", "cclk"; bosch,mram-cfg =3D <0x0 128 64 64 64 64 32 32>; + wakeup-source; status =3D "disabled"; }; }; --=20 2.45.2 From nobody Tue Nov 26 21:36:32 2024 Received: from mail-ej1-f52.google.com (mail-ej1-f52.google.com [209.85.218.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D61B11FE10E for ; Tue, 15 Oct 2024 19:17:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019844; cv=none; b=MmbOiwF4lsnfuCgSGALO4rE33ohLCy8vUeAlG9LNRDJ7ipcgOE1IcD2HCf1KAbT4U6kUIP+kw3Y3o9wwZsirwtGemuUBYth28ELcB9v9GURRBavSHdxCZ9uqXzY2jMeL08yV4ulehq7ruzMpYjmQBSJTfl79G0ZqC2Se0k578mg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729019844; c=relaxed/simple; bh=Mzxbq0cogQNrwowj1zfIE0DVBGY5w4Uyxw7H3xobrQ4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=FQUl241Zm+c1nogON9X1wnF17Ue+FQ4C8vo+C+LWSv+KDEWE15uWT3ZklJ8IdRtU3yNFirINA2CcF4+CuROLSBepC9l4Q8BdMwTpOEOcnIOzwTs6zM/A0FR2ddMvLtPXwin1fVMu6fWd4Et4axMPJ9ytgPCY/4m7sTk1OJ3YGbA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=a5qzwe3f; arc=none smtp.client-ip=209.85.218.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="a5qzwe3f" Received: by mail-ej1-f52.google.com with SMTP id a640c23a62f3a-a9a0c40849cso394594066b.3 for ; Tue, 15 Oct 2024 12:17:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1729019840; x=1729624640; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=U0ITVZ/ruKG/TLGpfGAwzLMygWSysjucbld18q4vTYY=; b=a5qzwe3f6tK9/R7s61yQfB1pNI6YhyoXKhIc/YSpkQeZs9KouGICNxmGqn+eknUaRd 65qGejTZgYBSRFdFs1E2DDR+oHUEx09A7PZpqJ+nBLefFXK0PVIFByHE3NJdzPigvaO9 HS/A5clVzA5uMtMe+SJp5Er/M97RG6nQOKD86SQJJ50aT8jCtKp/OJnBy94rFu4EdUL3 X0mrbdsvAJHR+k4JuElxUq2zb71qfNS2CY2c0H1aKBkgIGykg2ER51r5FGkyjQk4T2k7 ypQObybFBwVyJ39VSyw3xwjxP6/h4ESEbRsc03AdnEUHKKFJEKjHKcYKdOp6AJ3jYZ1C 5qsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729019840; x=1729624640; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=U0ITVZ/ruKG/TLGpfGAwzLMygWSysjucbld18q4vTYY=; b=g/4ZG6VZ0JT+jOlAXALKaRM3Vl7Y6desPROECN30fUBn8giisYiyVTP/N7Li9LSxoo nj3D7ymswinA82xhVrm/Ez7HBnhPjJfsyigys8yrLHScz2FFOgBNBkPcz4MnoDM6sC3W aOZPhizqmYTmIF6ZNTlK1hVwcBIMwFnFJmXxEPnMIiQADxMPqbZJPCePwasoT5UfnnuP YzS8zD14SdY3yHa2/wuLMxUQ6H45xg9ZWM1PKK0Ob+/IXXkZOXqGfYizpiy30Im3Xk2c SD9/b/6NyI1zx5XXeFsFeWKde1tQO4eF+cyyLZOaEgNZE96Hm8zhik7dAK/zev+nKznI DE3g== X-Forwarded-Encrypted: i=1; AJvYcCVwAslSBq7W3djzXXihMkRuB5CGLBfCLDDHLV7U5dl98zLOPF+OCjdWGdguEBwnbugGRO68RA9kDmFP3xA=@vger.kernel.org X-Gm-Message-State: AOJu0YxCFDNuBW+ak6n3olomqFy9I6li1/pbCA/p4tEj1/Ub2RdZJPdG nVvwp8k7bFsq9Da0V1gzFKGSSjPJli5jHRVIFpo/ASij3igSkpfkOo9MFKJjjT0= X-Google-Smtp-Source: AGHT+IFE3zU2wsWTaMuFRX4RT0/Jxds4c9H2MyVuhIDmZBUP8boAZj8D2JLinmI6aBazvsto4DV1Nw== X-Received: by 2002:a17:907:3f8f:b0:a99:f746:385 with SMTP id a640c23a62f3a-a99f746105fmr1163295466b.1.1729019840193; Tue, 15 Oct 2024 12:17:20 -0700 (PDT) Received: from localhost ([2001:4090:a244:83ae:2517:2666:43c9:d0d3]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9a29749540sm101289166b.76.2024.10.15.12.17.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 12:17:19 -0700 (PDT) From: Markus Schneider-Pargmann Date: Tue, 15 Oct 2024 21:16:03 +0200 Subject: [PATCH v4 9/9] arm64: dts: ti: k3-am62p-mcu: Mark mcu_mcan0/1 as wakeup-source Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20241015-topic-mcan-wakeup-source-v6-12-v4-9-fdac1d1e7aa6@baylibre.com> References: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> In-Reply-To: <20241015-topic-mcan-wakeup-source-v6-12-v4-0-fdac1d1e7aa6@baylibre.com> To: Chandrasekar Ramakrishnan , Marc Kleine-Budde , Vincent Mailhol , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Nishanth Menon , Vignesh Raghavendra , Tero Kristo Cc: linux-can@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Matthias Schiffer , Vishal Mahaveer , Kevin Hilman , Dhruva Gole , Simon Horman , Vincent MAILHOL , Markus Schneider-Pargmann X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1170; i=msp@baylibre.com; h=from:subject:message-id; bh=Tq/fbr0WhZHR5UVyg7x0DcqyPJVYjETLUN6TQAqpB5E=; b=owGbwMvMwCGm0rPl0RXRdfaMp9WSGNL59q9r6nha9Hh5SuMeznWH2r4sOONbuO/kHN3Ls+fGu Syurd9/vqOUhUGMg0FWTJHl7oeF7+rkri+IWPfIEWYOKxPIEAYuTgGYyPpqhn92rt2Nr1as3zBp iqqu7MKwdG2e72VxM0NEmzz/ay+Y8v4dw/+0xo+R89ulZlmvn9J26sPnrSva7yu+i1wZ38bg8n+ i8noOAA== X-Developer-Key: i=msp@baylibre.com; a=openpgp; fpr=BADD88DB889FDC3E8A3D5FE612FA6A01E0A45B41 From: Vibhore Vardhan mcu_mcan0 and mcu_mcan1 can be wakeup sources for the SoC. Mark them accordingly in the devicetree. Based on the patch for AM62a. Signed-off-by: Vibhore Vardhan Signed-off-by: Markus Schneider-Pargmann --- arch/arm64/boot/dts/ti/k3-am62p-j722s-common-mcu.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-am62p-j722s-common-mcu.dtsi b/arch/a= rm64/boot/dts/ti/k3-am62p-j722s-common-mcu.dtsi index b33aff0d65c9def755f8dda9eb9feda7bc74e5c8..3afa17e6592f39387a667547835= c90f95a9af351 100644 --- a/arch/arm64/boot/dts/ti/k3-am62p-j722s-common-mcu.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62p-j722s-common-mcu.dtsi @@ -173,6 +173,7 @@ mcu_mcan0: can@4e08000 { interrupts =3D , ; interrupt-names =3D "int0", "int1"; + wakeup-source; status =3D "disabled"; }; =20 @@ -188,6 +189,7 @@ mcu_mcan1: can@4e18000 { interrupts =3D , ; interrupt-names =3D "int0", "int1"; + wakeup-source; status =3D "disabled"; }; =20 --=20 2.45.2