All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vinod Koul <vkoul@kernel.org>
To: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com>
Cc: Neil Armstrong <neil.armstrong@linaro.org>,
	Manivannan Sadhasivam <mani@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Thinh Nguyen <Thinh.Nguyen@synopsys.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	linux-usb@vger.kernel.org,
	Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
Subject: Re: [PATCH v8 2/5] include: linux: phy: Add phy attribute "type" and associated helpers
Date: Thu, 12 Nov 2026 13:55:43 +0530	[thread overview]
Message-ID: <avV4B4g-NWtZbLuX@parshuram> (raw)
In-Reply-To: <033c8432-4a03-4f38-b0a3-28f5d551b0ef@oss.qualcomm.com>

On 27-10-26, 13:37, Krishna Kurapati wrote:
> 
> 
> On 10/9/2026 10:29 PM, Krishna Kurapati wrote:
> > 
> > 
> > On 10/5/2026 2:14 PM, Vinod Koul wrote:
> > > On 13-09-26, 20:10, Krishna Kurapati wrote:
> > > > In cases like USB High-speed phys which can be either USB2 or
> > > > EUSB2, it is
> > > > required to know the type of phy (rather than the operating
> > > > mode) because
> > > > DP and DM interrupt lines need to be configured differently for each of
> > > > them.
> > > 
> > > Does the controller care? In preceding patch you defined the EUSB2 in dt
> > > type, so this describes the hardware. So phy knows it is usb or eusb...
> > > > 
> > 
> > Controller is agnostic of whether the phy is usb2 or eusb2. Phy does now
> > its type, but it needs to communicate the same to controller.
> > 
> > > > Add support to cache the PHY_TYPE and add the following helpers:
> > > > 
> > > > - phy_set_type() for the phy drivers (like m31_eusb2 or snps-eusb2) to
> > > > declare what type of PHY they are (in this case PHY_TYPE_EUSB2).
> > > > 
> > > > - phy_get_type() for the consumers (like USB controllers) to query the
> > > > type of phy connected to them.
> > > 
> > > I am not convinced that this is the way to go... Driver already knows
> > > the type and should use it...
> > > we alreayd have mode, i am inclined to not say yes to adding type here
> > > 
> > 
> > "Mode" attribute describes the current operating scenario of the phy
> > (device mode, host mode, high speed, super speed etc.,). But it doesn't
> > describe the type of hardware and hence a new attribute.

Not really. A combo phy can be usb/type c and we do set that mode...

> > 
> 
> Vinod, can you please let know if you are fine with this approach. If yes, I
> will send v9 rebased on top of phy-next.

I am not convinced that this is the way to go..

-- 
~Vinod

WARNING: multiple messages have this Message-ID (diff)
From: Vinod Koul <vkoul@kernel.org>
To: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com>
Cc: Neil Armstrong <neil.armstrong@linaro.org>,
	Manivannan Sadhasivam <mani@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Thinh Nguyen <Thinh.Nguyen@synopsys.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-phy@lists.infradead.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	linux-usb@vger.kernel.org,
	Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
Subject: Re: [PATCH v8 2/5] include: linux: phy: Add phy attribute "type" and associated helpers
Date: Thu, 12 Nov 2026 13:55:43 +0530	[thread overview]
Message-ID: <avV4B4g-NWtZbLuX@parshuram> (raw)
In-Reply-To: <033c8432-4a03-4f38-b0a3-28f5d551b0ef@oss.qualcomm.com>

On 27-10-26, 13:37, Krishna Kurapati wrote:
> 
> 
> On 10/9/2026 10:29 PM, Krishna Kurapati wrote:
> > 
> > 
> > On 10/5/2026 2:14 PM, Vinod Koul wrote:
> > > On 13-09-26, 20:10, Krishna Kurapati wrote:
> > > > In cases like USB High-speed phys which can be either USB2 or
> > > > EUSB2, it is
> > > > required to know the type of phy (rather than the operating
> > > > mode) because
> > > > DP and DM interrupt lines need to be configured differently for each of
> > > > them.
> > > 
> > > Does the controller care? In preceding patch you defined the EUSB2 in dt
> > > type, so this describes the hardware. So phy knows it is usb or eusb...
> > > > 
> > 
> > Controller is agnostic of whether the phy is usb2 or eusb2. Phy does now
> > its type, but it needs to communicate the same to controller.
> > 
> > > > Add support to cache the PHY_TYPE and add the following helpers:
> > > > 
> > > > - phy_set_type() for the phy drivers (like m31_eusb2 or snps-eusb2) to
> > > > declare what type of PHY they are (in this case PHY_TYPE_EUSB2).
> > > > 
> > > > - phy_get_type() for the consumers (like USB controllers) to query the
> > > > type of phy connected to them.
> > > 
> > > I am not convinced that this is the way to go... Driver already knows
> > > the type and should use it...
> > > we alreayd have mode, i am inclined to not say yes to adding type here
> > > 
> > 
> > "Mode" attribute describes the current operating scenario of the phy
> > (device mode, host mode, high speed, super speed etc.,). But it doesn't
> > describe the type of hardware and hence a new attribute.

Not really. A combo phy can be usb/type c and we do set that mode...

> > 
> 
> Vinod, can you please let know if you are fine with this approach. If yes, I
> will send v9 rebased on top of phy-next.

I am not convinced that this is the way to go..

-- 
~Vinod

-- 
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy

  reply	other threads:[~2026-11-12  8:25 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-13 14:40 [PATCH v8 0/5] Modify interrupt handling for eUSB2 Phy targets Krishna Kurapati
2026-09-13 14:40 ` Krishna Kurapati
2026-09-13 14:40 ` [PATCH v8 1/5] dt-bindings: phy: Add PHY_TYPE_EUSB2 definition Krishna Kurapati
2026-09-13 14:40   ` Krishna Kurapati
2026-09-13 14:40 ` [PATCH v8 2/5] include: linux: phy: Add phy attribute "type" and associated helpers Krishna Kurapati
2026-09-13 14:40   ` Krishna Kurapati
2026-10-05  8:44   ` Vinod Koul
2026-10-05  8:44     ` Vinod Koul
2026-10-09 16:59     ` Krishna Kurapati
2026-10-09 16:59       ` Krishna Kurapati
2026-10-27  8:07       ` Krishna Kurapati
2026-10-27  8:07         ` Krishna Kurapati
2026-11-12  8:25         ` Vinod Koul [this message]
2026-11-12  8:25           ` Vinod Koul
2026-11-12  9:15           ` Krishna Kurapati
2026-11-12  9:15             ` Krishna Kurapati
2026-11-24  9:18   ` Arnd Bergmann
2026-11-24  9:18     ` Arnd Bergmann
2026-11-24 14:24     ` Greg Kroah-Hartman
2026-11-24 14:24       ` Greg Kroah-Hartman
2026-09-13 14:40 ` [PATCH v8 3/5] phy: snps-eusb2: Set phy type to EUSB2 Krishna Kurapati
2026-09-13 14:40   ` Krishna Kurapati
2026-09-13 14:40 ` [PATCH v8 4/5] phy: qcom: m31-eusb2: " Krishna Kurapati
2026-09-13 14:40   ` Krishna Kurapati
2026-09-13 14:40 ` [PATCH v8 5/5] usb: dwc3: qcom: Modify interrupt handling for eUSB2 Phy targets Krishna Kurapati
2026-09-13 14:40   ` Krishna Kurapati
2026-09-13 14:53   ` sashiko-bot
2026-09-13 14:53     ` sashiko-bot
2026-10-04  9:34 ` [PATCH v8 0/5] " Joonhoe Kim
2026-10-04  9:34   ` Joonhoe Kim

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=avV4B4g-NWtZbLuX@parshuram \
    --to=vkoul@kernel.org \
    --cc=Thinh.Nguyen@synopsys.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=krishna.kurapati@oss.qualcomm.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-phy@lists.infradead.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mani@kernel.org \
    --cc=manivannan.sadhasivam@oss.qualcomm.com \
    --cc=neil.armstrong@linaro.org \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.