Hi,
> On 03.08.2012 02:54, B, Ravi wrote:
> >> On 02.08.2012 14:12, Ravi Babu wrote:
> >>> This series of patches adds,
> >>> a) Multi instances support in musb driver
> >>> b) DT support for musb_dsps glue layer
> >>> c) DT support for NOP transceiver
> >>>
> >>> AM33xx and TI81xx has dual musb co
Hi,
I am using v3.5 kernel and running a test where I disconnect a SS MSC
device while a big file is being written to it. I am also watching the
lsusb output in parallel. Expectation is that SS MSC device should
immediately disappear from lsusb output but sometime I see that SS MSC
is listed for 3
Hi,
>> I am using v3.5 kernel and running a test where I disconnect
>> a SS MSC device while a big file is being written to it. I am
>> also watching the lsusb output in parallel. Expectation is
>> that SS MSC device should immediately disappear from lsusb
>> output but sometime I see that SS MSC i
Hi Sarah
On Thu, Sep 13, 2012 at 2:37 AM, Sarah Sharp
wrote:
> On Wed, Sep 12, 2012 at 03:36:39PM +0530, Ajay Gupta wrote:
>> Hi,
>>
>> I am using v3.5 kernel and running a test where I disconnect a SS MSC
>> device while a big file is being written to it. I am also w
Hi
>> >> I am using v3.5 kernel and running a test where I disconnect a SS MSC
>> >> device while a big file is being written to it. I am also watching the
>> >> lsusb output in parallel. Expectation is that SS MSC device should
>> >> immediately disappear from lsusb output but sometime I see that
Hi,
> Ajay, which host controller are you seeing the disconnect lags on? Can you
> send me the output of `sudo lspci -vvv -n`?
I was on leave last week so will get the data at earliest.
Ajay
>
> Sarah Sharp
> --
> To unsubscribe from this list: send the line "unsubscribe linux-usb" in the
> b
Hi Heikki,
> -Original Message-
> From: linux-usb-ow...@vger.kernel.org On
> Behalf Of Heikki Krogerus
> Sent: Wednesday, March 20, 2019 4:45 AM
> To: Ajay Gupta ; Michael Hsu
> Cc: linux-usb@vger.kernel.org
> Subject: [PATCH v2 0/2] usb: typec: ucsi: Support fo
From: Ajay Gupta
Latest NVIDIA GPUs support VirtualLink device. Since USBIF
has not assigned a Standard ID (SID) for VirtualLink
so using NVIDA VID 0x955 as SVID.
Signed-off-by: Ajay Gupta
---
drivers/usb/typec/altmodes/Kconfig | 10 +++
drivers/usb/typec/altmodes/Makefile | 2
d two warnings from checkpatch.pl script -Ajay]
Signed-off-by: Heikki Krogerus
Signed-off-by: Ajay Gupta
Tested-by: Ajay Gupta
---
drivers/usb/typec/altmodes/displayport.c | 12 +++-
drivers/usb/typec/altmodes/displayport.h | 8
2 files changed, 15 insertions(+), 5 deletions(-)
c
l and patches
at [1] forwarded to Greg from you.
[1] https://marc.info/?l=linux-usb&m=155488414908414&w=2
Thanks
Ajay
Ajay Gupta (1):
usb: typec: Add driver for NVIDIA Alt Modes
Heikki Krogerus (1):
usb: typec: displayport: Export probe and remove functions
drivers/usb/typec/alt
Function is to get the details of ccg firmware and device version.
It will be useful in debugging and also during firmware update.
Signed-off-by: Ajay Gupta
Signed-off-by: Heikki Krogerus
---
Changes from v5 to v6
- None
drivers/usb/typec/ucsi/ucsi_ccg.c | 66
://marc.info/?l=linux-usb&m=155491396220133&w=2
[2] https://marc.info/?l=linux-usb&m=155006182508289&w=2
Ajay Gupta (2):
usb: typec: ucsi: ccg: add get_fw_info function
usb: typec: ucsi: ccg: add firmware flashing support
drivers/usb/typec/ucsi/ucsi_ccg.c | 887 +
port number information is added which is required while sending
PD_PORT_ENABLE command
Signed-off-by: Ajay Gupta
---
Changes from v5 to v6
- Fixed below sparse warnings
"restricted __le16 degrades to integer"
drivers/usb/typec/ucsi/ucsi_c
Hi Heikki,
> -Original Message-
> From: Heikki Krogerus
> Sent: Thursday, April 11, 2019 12:40 AM
> To: Ajay Gupta
> Cc: kbuild test robot ; kbuild-...@01.org; Greg Kroah-Hartman
> ; linux-usb@vger.kernel.org
> Subject: Re: [PATCH 2/4] usb: typec: ucsi: ccg:
Hi Heikki,
> -Original Message-
> From: linux-usb-ow...@vger.kernel.org On
> Behalf Of Heikki Krogerus
> Sent: Friday, April 12, 2019 8:02 AM
> To: Ajay Gupta
> Cc: linux-usb@vger.kernel.org; Ajay Gupta
> Subject: Re: [PATCH v6 2/2] usb: typec: ucsi: ccg:
tails are at [2].
Please help review this set.
Thanks
Ajay
[1] https://marc.info/?l=linux-usb&m=155508466310059&w=2
[2] https://marc.info/?l=linux-usb&m=155006182508289&w=2
Ajay Gupta (2):
usb: typec: ucsi: ccg: add get_fw_info function
usb: typec: ucsi: ccg: add firmware flashi
Function is to get the details of ccg firmware and device version.
It will be useful in debugging and also during firmware update.
Signed-off-by: Ajay Gupta
Signed-off-by: Heikki Krogerus
---
Changes from v6 to v7
- None
drivers/usb/typec/ucsi/ucsi_ccg.c | 66
From: Heikki Krogerus
Adding device property "ccgx,firmware-build" for the CCGx
device, so the CCGx driver knows which firmware binary to
use for a specific vendor.
Signed-off-by: Heikki Krogerus
Signed-off-by: Ajay Gupta
---
drivers/i2c/busses/i2c-nvidia-gpu.c | 7 +++
1 file
port number information is added which is required while sending
PD_PORT_ENABLE command
Signed-off-by: Ajay Gupta
---
Changes from v6 -> v7
- Read fw_build from device property
- remove unused level ccg_check_fw_version()
drivers/usb/typec/ucsi/ucsi_ccg.c |
Hi Heikki,
> -Original Message-
> From: linux-usb-ow...@vger.kernel.org On
> Behalf Of Heikki Krogerus
> Sent: Monday, April 15, 2019 5:10 AM
> To: Greg Kroah-Hartman
> Cc: Ajay Gupta ; linux-usb@vger.kernel.org
> Subject: [PATCH v2 6/7] usb: typec: displayport: Ex
://marc.info/?l=linux-usb&m=15554931927&w=2
[2] https://marc.info/?l=linux-usb&m=155006182508289&w=2
Ajay Gupta (2):
usb: typec: ucsi: ccg: add get_fw_info function
usb: typec: ucsi: ccg: add firmware flashing support
Heikki Krogerus (1):
i2c: nvidia-gpu: Supply CCGx driver t
From: Ajay Gupta
Function is to get the details of ccg firmware and device version.
It will be useful in debugging and also during firmware update.
Signed-off-by: Ajay Gupta
Signed-off-by: Heikki Krogerus
---
Changes from v7 -> v8
- None
drivers/usb/typec/ucsi/ucsi_ccg.c |
From: Ajay Gupta
Adding device property "ccgx,firmware-build" for the CCGx
device, so the CCGx driver knows which firmware binary to
use for a specific vendor.
Suggested-by: Heikki Krogerus
Signed-off-by: Ajay Gupta
Signed-off-by: Heikki Krogerus
---
Changes from v7->v8
From: Ajay Gupta
CCGx has two copies of the firmware in addition to the bootloader.
If the device is running FW1, FW2 can be updated with the new version.
Dual firmware mode allows the CCG device to stay in a PD contract and
support USB PD and Type-C functionality while a firmware update is in
Hi Wei
> -Original Message-
> From: Wei Yongjun
> Sent: Monday, April 29, 2019 5:27 AM
> To: Heikki Krogerus ; Greg Kroah-Hartman
> ; Ajay Gupta ; Wolfram Sang
>
> Cc: Wei Yongjun ; linux-usb@vger.kernel.org;
> kernel-janit...@vger.kernel.org
> Subject: [PA
From: Ajay Gupta
The change enables runtime pm support to UCSI CCG driver.
ucsi_send_command() is used in resume path and so exported
ucsi_send_command() symbol in ucsi.c for modular build.
Signed-off-by: Ajay Gupta
---
drivers/usb/typec/ucsi/ucsi.c | 1 +
drivers/usb/typec/ucsi
From: Ajay Gupta
Enable runtime pm support with autosuspend delay of three second.
This is to make sure I2C client device Cypress CCGx has completed
all transaction.
Signed-off-by: Ajay Gupta
---
drivers/i2c/busses/i2c-nvidia-gpu.c | 24 +---
1 file changed, 21 insertions
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware verson 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. Many of these cards may get latest kernel but
may not get
s new kernel then also it
should continue to work.
Thanks
Ajay
Ajay Gupta (4):
i2c: nvidia-gpu: add runtime pm support
usb: typec: ucsi: ccg: enable runtime pm support
i2c: nvidia-gpu: resume ccgx i2c client
usb: typec: ucsi: ccg: add runtime pm workaround
drivers/i2c/busses/i2c-nvidia-gpu.c
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware (which is being used
in many NVIDIA GPU cards) has known issue of not triggering
interrupt when a USB device is hot plugged to runtime resume the
controller. Many of these cards may get latest kernel but may not
get latest fixed
Hi Wolfram,
> -Original Message-
> From: Wolfram Sang
> Sent: Sunday, May 19, 2019 7:47 AM
> To: Ajay Gupta
> Cc: heikki.kroge...@linux.intel.com; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay Gupta
> Subject: Re: [PATCH 1/4] i2c: nvidia-gpu: a
Hi Wolfram,
> -Original Message-
> From: Wolfram Sang
> Sent: Sunday, May 19, 2019 7:49 AM
> To: Ajay Gupta
> Cc: heikki.kroge...@linux.intel.com; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay Gupta
> Subject: Re: [PATCH 3/4] i2c: nvidia-gpu: r
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
Enable runtime pm support with autosuspend delay of three second.
This is to make sure I2C client device Cypress CCGx has completed
all transaction.
Signed-off-by: Ajay Gupta
---
Changes from v1->v2: None
drivers/i2c/busses/i2c-nvidia-gpu.c | 19 ++-
1 f
eries.
Thanks
Ajay
Ajay Gupta (5):
i2c: nvidia-gpu: refactor master_xfer
i2c: nvidia-gpu: add runtime pm support
usb: typec: ucsi: ccg: enable runtime pm support
i2c: nvidia-gpu: resume ccgx i2c client
usb: typec: ucsi: ccg: add runtime pm workaround
drivers/i2c/busses/i2c-nvidia-
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
Added a local variable "send_stop" to simplify "goto" statements.
The "send_stop" handles below two case
1) When first i2c start fails and so i2c stop is not sent before
exiting
2) When i2c stop failed after all transfers and we do not need to
se
From: Ajay Gupta
The change enables runtime pm support to UCSI CCG driver.
ucsi_send_command() is used in resume path and so exported
ucsi_send_command() symbol in ucsi.c for modular build.
Signed-off-by: Ajay Gupta
---
Changes from v1->v2 : None
drivers/usb/typec/ucsi/ucsi.c |
Hi Heikki
> > +static int ucsi_ccg_resume(struct device *dev) {
> > + struct i2c_client *client = to_i2c_client(dev);
> > + struct ucsi_ccg *uc = i2c_get_clientdata(client);
> > + struct ucsi *ucsi = uc->ucsi;
> > + struct ucsi_control c;
> > + int ret;
> > +
> > + /* restore UCSI noti
From: Ajay Gupta
Added a local variable "send_stop" to simplify "goto" statements.
The "send_stop" handles below two case
1) When first i2c start fails and so i2c stop is not sent before
exiting
2) When i2c stop failed after all transfers and we do not need to
se
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
The change enables runtime pm support to UCSI CCG driver.
Added ucsi_resume() function to enable notification after
system reusme. Exported both ucsi_resume() and ucsi_send_command()
symbols in ucsi.c for modular build.
Signed-off-by: Ajay Gupta
---
Changes from v2->v3 : N
me pm wokaround. I would prefer it to go through
usb-tree since usb ucsi_ccg driver is the main driver getting runtime pm
functionality with the series.
Thanks
Ajay
Ajay Gupta (5):
i2c: nvidia-gpu: refactor master_xfer
i2c: nvidia-gpu: add runtime pm support
usb: typec: ucsi: ccg: enable runti
From: Ajay Gupta
Enable runtime pm support with autosuspend delay of three second.
This is to make sure I2C client device Cypress CCGx has completed
all transaction.
Signed-off-by: Ajay Gupta
---
Changes from v1->v2:
- Added __maybe_unused in gpu_i2c_suspend to avoid
warn
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
Hi Wolfram,
> -Original Message-
> From: linux-usb-ow...@vger.kernel.org
> On Behalf Of Wolfram Sang
> Sent: Saturday, May 25, 2019 12:57 PM
> To: Ajay Gupta
> Cc: heikki.kroge...@linux.intel.com; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay
Hi Wolfram,
> > -Original Message-
> > From: linux-usb-ow...@vger.kernel.org ow...@vger.kernel.org>
> > On Behalf Of Wolfram Sang
> > Sent: Saturday, May 25, 2019 12:57 PM
> > To: Ajay Gupta
> > Cc: heikki.kroge...@linux.intel.com;
tches should go together since ucsi_ccg driver is dependent
on i2c driver for runtime pm wokaround. I would prefer it to go through
usb-tree since usb ucsi_ccg driver is the main driver getting runtime pm
functionality with the series.
Thanks
Ajay
Ajay Gupta (5):
i2c: nvidia-gpu: ref
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
Added a local variable "send_stop" to simplify "goto" statements.
The "send_stop" handles below two case
1) When first i2c start fails and so i2c stop is not sent before
exiting
2) When i2c stop failed after all transfers and we do not need to
se
From: Ajay Gupta
Enable runtime pm support with autosuspend delay of three second.
This is to make sure I2C client device Cypress CCGx has completed
all transaction.
Signed-off-by: Ajay Gupta
---
Changes from v3->v4:
- Added comment on why stub gpu_i2c_suspend() is needed
From: Ajay Gupta
The change enables runtime pm support to UCSI CCG driver.
Added ucsi_resume() function to enable notification after
system reusme. Exported both ucsi_resume() and ucsi_send_command()
symbols in ucsi.c for modular build.
Signed-off-by: Ajay Gupta
---
Changes from v3->v4 : N
Hi Heikki and Wolfram,
> -Original Message-
> From: linux-i2c-ow...@vger.kernel.org
> On Behalf Of Wolfram Sang
> Sent: Friday, June 7, 2019 1:27 AM
> To: Heikki Krogerus
> Cc: Ajay Gupta ; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay Gupta
>
Hi Wolfram,
> -Original Message-
> From: Wolfram Sang
> Sent: Friday, June 7, 2019 1:33 AM
> To: Ajay Gupta
> Cc: heikki.kroge...@linux.intel.com; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay Gupta
> Subject: Re: [PATCH v4 1/5] i2c: nvidia-gpu:
Hi Wolfram,
> -Original Message-
> From: linux-i2c-ow...@vger.kernel.org
> On Behalf Of Wolfram Sang
> Sent: Friday, June 7, 2019 1:33 AM
> To: Ajay Gupta
> Cc: heikki.kroge...@linux.intel.com; linux-usb@vger.kernel.org; linux-
> i...@vger.kernel.org; Ajay Gupta
From: Ajay Gupta
Added a local variable "send_stop" to simplify "goto" statements.
The "send_stop" handles below two case
1) When first i2c start fails and so i2c stop is not sent before
exiting
2) When i2c stop failed after all transfers and we do not need to
se
mware with
the known issue.
All the five patches should go together since ucsi_ccg driver is dependent
on i2c driver for runtime pm wokaround. I would prefer it to go through
usb-tree since usb ucsi_ccg driver is the main driver getting runtime pm
functionality with the series.
Thanks
Ajay
Ajay
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
From: Ajay Gupta
The change enables runtime pm support to UCSI CCG driver.
Added ucsi_resume() function to enable notification after
system reusme. Exported both ucsi_resume() and ucsi_send_command()
symbols in ucsi.c for modular build.
Signed-off-by: Ajay Gupta
Acked-by: Heikki Krogerus
From: Ajay Gupta
Enable runtime pm support with autosuspend delay of three second.
This is to make sure I2C client device Cypress CCGx has completed
all transaction.
Signed-off-by: Ajay Gupta
---
Changes from v4->v5:
- Removed extra comments for gpu_i2c_suspend() based
From: Ajay Gupta
Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but
modes into one.
Signed-off-by: Ajay Gupta
---
drivers/usb/typec/ucsi/ucsi.c | 191 +-
drivers/usb/typec/ucsi/ucsi.h | 12 +++
2 files changed, 199 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/typec/ucsi/ucsi.c b/drivers/usb/typec/ucsi/ucsi.c
index ba288b9
Hi Heikki,
> On Jun 28, 2019, at 3:47 AM, Heikki Krogerus
> wrote:
>
>> On Thu, Jun 27, 2019 at 10:45:47PM -0700, Ajay Gupta wrote:
>> CCGx controller used on NVIDIA GPU card has two separate display
>> altmode for two DP pin assignments. UCSI specification doesn
From: Ajay Gupta
CCGx controller used on NVIDIA GPU card has two separate display
altmode for two DP pin assignments. UCSI specification doesn't
prohibits using separate display altmode.
Current UCSI Type-C framework expects only one display altmode for
all DP pin assignment. This
From: Ajay Gupta
CCGx controller used on NVIDIA GPU card has two separate display
altmode for two DP pin assignments. UCSI specification doesn't
prohibits using separate display altmode.
Current UCSI Type-C framework expects only one display altmode for
all DP pin assignment. This
Some controllers take almost 55ms to complete controller
restore state (CRS).
There is no timeout limit mentioned in xhci specification so
fix the issue by increasing the timeout limit to 55ms
Signed-off-by: Ajay Gupta
Signed-off-by: Nagaraj Annaiah
---
drivers/usb/host/xhci.c | 2 +-
1 file
Some controllers take almost 55ms to complete controller
restore state (CRS).
There is no timeout limit mentioned in xhci specification so
fixing the issue by increasing the timeout limit to 55ms
Signed-off-by: Ajay Gupta
Signed-off-by: Nagaraj Annaiah
---
drivers/usb/host/xhci.c | 7
Some controllers take almost 55ms to complete controller
restore state (CRS).
There is no timeout limit mentioned in xhci specification so
fixing the issue by increasing the timeout limit to 100ms
Signed-off-by: Ajay Gupta
Signed-off-by: Nagaraj Annaiah
---
Changes from v2->v3
Updated com
Hi Loic
On 6/21/18, Loic Poulain wrote:
> Most of FTDI's devices have an EEPROM which records FTDI devices
> configuration setting (e.g. the VID, PID, I/O config...) and user
> data. FT230R chip integrates a 128-byte eeprom, FT230X a 2048-byte
> eeprom...
>
> This patch adds support for FTDI EEPR
> Reviewed-by: Andy Shevchenko
> Signed-off-by: Loic Poulain
Reviewed-by: Ajay Gupta
> ---
> v2: Use ifdef instead of IS_ENABLED
> error message in case of nvmem registering failure
> Fix space/tab in Kconfig
> v3: Make nvmem a child of the usb dev instead of the s
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver add I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
---
Documentation/i2c/busses
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
drivers/usb/typec/ucsi/Kconfig| 10 +
drivers/usb/typec/ucsi/Makefile
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver add I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2: N
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2:
Fixed identation in drivers/usb/typec/ucsi/Kconfig
drivers/
Hi Andy,
> > Latest NVIDIA GPU card has USB Type-C interface. There is a
> > Type-C controller which can be accessed over I2C.
> >
> > This driver add I2C bus driver to communicate with Type-C controller.
> > I2C client driver will be part of USB Type-C UCSI driver.
>
> > drivers/i2c/busses/i2c-
-- /dev/null
> > +++ b/Documentation/i2c/busses/i2c-gpu
>
> I think this is too generic. Maybe use something like i2c-nvidia-gpu here and
> everywhere else, to make it explicit that this is for NVIDIA GPUs rather than
> GPUs in general.
ok
> > @@ -0,0 +1,18 @@
> >
Hi Heikki,
> On Fri, Aug 24, 2018 at 02:33:36PM -0700, Ajay Gupta wrote:
> > Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
> > over I2C interface.
> >
> > This UCSI I2C driver uses I2C bus driver interface for communicating
> > with Type-C contr
.
> >
>
> Some small comments below, after addressing them
>
> Reviewed-by: Andy Shevchenko
>
> > Signed-off-by: Ajay Gupta
> > ---
> > Changes from v1 -> v2
> > None
> > Changes from v2 -> v3
> >
irq_handler(int irq, void *data) {
> > + struct ucsi_ccg *uc = data;
> > +
> > + ucsi_notify(uc->ucsi);
> > +
> > + return IRQ_HANDLED;
> > +}
> > +
>
> > +static int ucsi_ccg_probe(struct i2c_client *client,
> > +
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
---
Changes from v1 ->
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2
Fixed identation in drivers/usb/typec/ucsi/Kconfig
Chan
Hi Andy,
> > Latest NVIDIA GPU card has USB Type-C interface. There is a Type-C
> > controller which can be accessed over I2C.
> >
> > This driver adds I2C bus driver to communicate with Type-C controller.
> > I2C client driver will be part of USB Type-C UCSI driver.
>
> Thanks for an update, my c
Hi Andy
> > > Latest NVIDIA GPU card has USB Type-C interface. There is a Type-C
> > > controller which can be accessed over I2C.
> > > + val &= ~(I2C_MST_CNTL_GEN_START | I2C_MST_CNTL_GEN_STOP
> > > + | I2C_MST_CNTL_GEN_RAB);
> >
> > "|" should be on previous line to follow co
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
---
Changes from v1 ->
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2
Fixed identation in drivers/usb/typec/ucsi/Kconfig
Chan
Hi Andy,
> > Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller over I2C
> > interface.
> >
> > This UCSI I2C driver uses I2C bus driver interface for communicating
> > with Type-C controller.
>
> > Changes from v3 -> v4
> > Fixed comments from Andy
>
> Unfortunatelly not all c
Hi Greg,
> On Fri, Aug 31, 2018 at 01:22:21PM -0700, Ajay Gupta wrote:
> > + dev_info(dev, "Silicon id %2ph", data +
> CCGX_I2C_RAB_READ_SILICON_ID);
> > + dev_info(dev, "FW1 version %8ph\n", data +
> CCGX_I2C_RAB_FW1_VERSION);
> &g
Hi Greg,
> > +static int ccg_read(struct ucsi_ccg *uc, u16 rab, u8 *data, u32 len)
> > +{
> > + struct device *dev = uc->dev;
> > + struct i2c_client *client = uc->client;
> > + unsigned char buf[2];
> > + struct i2c_msg msgs[] = {
> > + {
> > + .addr = client
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
---
Changes from v1 ->
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2
Fixed identation in drivers/usb/typec/ucsi/Kconfig
Chan
dev_err(&pdev->dev, "pci_alloc_irq_vectors err %d\n",
> status);
> > + return status;
> > + }
> > +
> > + i2cd->do_start = true;
> > + mutex_init(&i2cd->mutex);
> > + enable_i2c_bus(i2cd);
>
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
Reviewed-by: Andy Shevchenko
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
Reviewed-by: Andy Shevchenko
Acked-by: Heikki Krogerus
---
Changes from v1 ->
+
> >>> + status = pci_alloc_irq_vectors(pdev, 1, 1, PCI_IRQ_MSI);
> >>> + if (status < 0) {
> >>> + dev_err(&pdev->dev, "pci_alloc_irq_vectors err %d\n",
> >> status);
> >>> + return status;
> >>> + }
> >>> +
> >>> + i2cd->do_start = true;
> >>> + mutex_init(&i2cd->mutex);
> >>> + enable_i2c_bus(i2cd);
> >>> +
> >>> + i2c_set_adapdata(&i2cd->adapter, i2cd);
> >>> + i2cd->adapter.owner = THIS_MODULE;
> >>> + strlcpy(i2cd->adapter.name, "NVIDIA GPU I2C adapter",
> >>> + sizeof(i2cd->adapter.name));
> >>> + i2cd->adapter.algo = &gpu_i2c_algorithm;
> >>> + i2cd->adapter.dev.parent = &pdev->dev;
> >>> + status = i2c_add_adapter(&i2cd->adapter);
> >>> + if (status < 0) {
> >>> + dev_err(&pdev->dev, "i2c_add_adapter failed %d\n", status);
> >>> + goto free_irq_vectors;
> >>> + }
> >>> +
> >>> + status = gpu_populate_client(i2cd, pdev->irq);
> >>> + if (status < 0) {
> >>> + dev_err(&pdev->dev, "gpu_populate_client failed %d\n",
> >> status);
> >>> + goto del_adapter;
> >>> + }
> >>> +
> >>> + return 0;
> >>> +
> >>> +del_adapter:
> >>> + i2c_del_adapter(&i2cd->adapter);
> >>> +free_irq_vectors:
> >>> + pci_free_irq_vectors(pdev);
> >>> + return status;
> >>> +}
> >>> +
> >>> +static void gpu_i2c_remove(struct pci_dev *pdev) {
> >>> + struct gpu_i2c_dev *i2cd = dev_get_drvdata(&pdev->dev);
> >>> +
> >>> + i2c_del_adapter(&i2cd->adapter);
> >>> + pci_free_irq_vectors(pdev);
> >>> +}
> >>> +
> >>> +static int gpu_i2c_resume(struct device *dev) {
> >>> + struct gpu_i2c_dev *i2cd = dev_get_drvdata(dev);
> >>> +
> >>> + enable_i2c_bus(i2cd);
> >>> + return 0;
> >>> +}
> >>> +
> >>> +static int gpu_i2c_idle(struct device *dev) {
> >>> + struct gpu_i2c_dev *i2cd = dev_get_drvdata(dev);
> >>> +
> >>> + if (!mutex_trylock(&i2cd->mutex)) {
> >>> + dev_info(dev, "-EBUSY\n");
> >>> + return -EBUSY;
> >>> + }
> >>> + mutex_unlock(&i2cd->mutex);
> >>> +
> >>> + return 0;
> >>> +}
> >>> +
> >>> +UNIVERSAL_DEV_PM_OPS(gpu_i2c_driver_pm, NULL, gpu_i2c_resume,
> >>> +gpu_i2c_idle);
> >>> +
> >>> +static struct pci_driver gpu_i2c_driver = {
> >>> + .name = "nvidia-gpu",
> >>> + .id_table = gpu_i2c_ids,
> >>> + .probe = gpu_i2c_probe,
> >>> + .remove = gpu_i2c_remove,
> >>> + .driver = {
> >>> + .pm = &gpu_i2c_driver_pm,
> >>> + },
> >>> +};
> >>> +
> >>> +module_pci_driver(gpu_i2c_driver);
> >>> +
> >>> +MODULE_AUTHOR("Ajay Gupta ");
> >>> +MODULE_DESCRIPTION("Nvidia GPU I2C controller Driver");
> >>> +MODULE_LICENSE("GPL v2");
> >>>
> >
= devm_kzalloc(dev, sizeof(*uc), GFP_KERNEL);
> > + if (!uc)
> > + return -ENOMEM;
> > +
> > + uc->ppm.data = devm_kzalloc(dev, sizeof(struct ucsi_data),
> GFP_KERNEL);
> > + if (!uc->ppm.data)
> > + return -ENOMEM;
> > +
> > + uc->ppm.cmd = ucsi_ccg_cmd;
> > + uc->ppm.sync = ucsi_ccg_sync;
> > + uc->dev = dev;
> > + uc->client = client;
> > +
> > + /* reset ccg device and initialize ucsi */
> > + status = ucsi_ccg_init(uc);
> > + if (status < 0) {
> > + dev_err(uc->dev, "ucsi_ccg_init failed - %d\n", status);
> > + return status;
> > + }
> > +
> > + uc->irq = client->irq;
> > +
> > + status = devm_request_threaded_irq(dev, uc->irq, NULL,
> ccg_irq_handler,
> > + IRQF_ONESHOT |
> IRQF_TRIGGER_HIGH,
> > + dev_name(dev), uc);
> > + if (status < 0) {
> > + dev_err(uc->dev, "request_threaded_irq failed - %d\n",
> status);
> > + return status;
> > + }
> > +
> > + uc->ucsi = ucsi_register_ppm(dev, &uc->ppm);
> > + if (IS_ERR(uc->ucsi)) {
> > + dev_err(uc->dev, "ucsi_register_ppm failed\n");
> > + return PTR_ERR(uc->ucsi);
> > + }
> > +
> > + i2c_set_clientdata(client, uc);
> > + return 0;
> > +}
> > +
> > +static int ucsi_ccg_remove(struct i2c_client *client) {
> > + struct ucsi_ccg *uc = i2c_get_clientdata(client);
> > +
> > + ucsi_unregister_ppm(uc->ucsi);
> > +
> > + return 0;
> > +}
> > +
> > +static const struct i2c_device_id ucsi_ccg_device_id[] = {
> > + {"ccgx-ucsi", 0},
> > + {}
> > +};
> > +MODULE_DEVICE_TABLE(i2c, ucsi_ccg_device_id);
> > +
> > +static struct i2c_driver ucsi_ccg_driver = {
> > + .driver = {
> > + .name = "ucsi_ccg",
> > + },
> > + .probe = ucsi_ccg_probe,
> > + .remove = ucsi_ccg_remove,
> > + .id_table = ucsi_ccg_device_id,
> > +};
> > +
> > +module_i2c_driver(ucsi_ccg_driver);
> > +
> > +MODULE_AUTHOR("Ajay Gupta ");
> > +MODULE_DESCRIPTION("UCSI driver for Cypress CCGx Type-C controller");
> > +MODULE_LICENSE("GPL v2");
> >
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
---
Changes from v1 -> v2
Fixed identation in drivers/usb/typec/ucsi/Kconfig
Chan
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
Reviewed-by: Andy Shevchenko
Latest NVIDIA GPU card has USB Type-C interface. There is a
Type-C controller which can be accessed over I2C.
This driver adds I2C bus driver to communicate with Type-C controller.
I2C client driver will be part of USB Type-C UCSI driver.
Signed-off-by: Ajay Gupta
Reviewed-by: Andy Shevchenko
Latest NVIDIA GPU cards have a Cypress CCGx Type-C controller
over I2C interface.
This UCSI I2C driver uses I2C bus driver interface for communicating
with Type-C controller.
Signed-off-by: Ajay Gupta
Reviewed-by: Andy Shevchenko
Acked-by: Heikki Krogerus
---
Changes from v1 ->
1 - 100 of 219 matches
Mail list logo