://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v4:
* used interface number from interface pointer instead of separate member var
Changes since v3:
* corrected typo
Changes since v2:
* Retrieved the i2c transfer status using interrupt in
> (..)
> > +config GPIO_CYUSBS23X
> > + tristate "CYUSBS23x GPIO support"
> > + depends on MFD_CYUSBS23X && USB
>
> Doesn't MFD_CYUSV23X already depend on USB?
Yes, removed USB from GPIO and I2C
> > + if (gpio->out_gpio & (1 << offset))
> > + return gpio->out_value
v/null
+++ b/drivers/gpio/gpio-cyusbs23x.c
@@ -0,0 +1,291 @@
+/*
+ * GPIO subdriver for Cypress CYUSBS234 USB-Serial Bridge controller.
+ * Details about the device can be found at:
+ *http://www.cypress.com/?rID=84126
+ *
+ * Copyright (c) 2014 Cypress Semiconductor Corporation.
+ *
+ * Au
ght (c) 2014 Cypress Semiconductor Corporation.
+ *
+ * Author:
+ * Muthu Mani
+ *
+ * Additional contributors include:
+ * Rajaram Regupathy
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 as publi
Hi,
Thanks for reviewing the code.
> > +/*
> > + * It exposes sysfs entries under the i2c adapter for getting the i2c
> > +transfer
> > + * status, reset i2c read/write module, get/set nak and stop bits.
> > + */
>
> Yes, I see that. Yet, I don't know why they are needed? The driver should
> know
> On Sat, Nov 29, 2014 at 11:49:04AM +0530, Muthu Mani wrote:
> > Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
> > CYUSBS234 USB-Serial Bridge controller.
> >
> > Details about the device can be found at:
> > http://www.cypress.com/?rID=84126
Thanks for your inputs.
> > +/* Serial interfaces (I2C, SPI, UART) differ in interface subclass */
> > +enum cy_scb_modes {
> > + CY_USBS_SCB_DISABLED = 0,
> > + CY_USBS_SCB_UART = 1,
> > + CY_USBS_SCB_SPI = 2,
> > + CY_USBS_SCB_I2C = 3
>
> Why have you numbered these indiv
* GPIO subdriver for Cypress CYUSBS234 USB-Serial Bridge controller.
+ * Details about the device can be found at:
+ *http://www.cypress.com/?rID=84126
+ *
+ * Copyright (c) 2014 Cypress Semiconductor Corporation.
+ *
+ * Author:
+ * Muthu Mani
+ *
+ * Additional contributors include:
+ *
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v3:
* corrected typo
Changes since v2:
* Retrieved the i2c transfer status using interrupt in endpoint
* Used kstrtol instead of manually parsing and scnprintf instead of sprintf
* Given i2c
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v3:
* Added devm_* allocation
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v3:
* corrected typo
Changes since v2:
* Retrieved the i2c transfer status using interrupt in endpoint
* Used kstrtol instead of manually parsing and scnprintf instead of sprintf
* Given i2c
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v3:
* Added devm_* allocation
* GPIO subdriver for Cypress CYUSBS234 USB-Serial Bridge controller.
+ * Details about the device can be found at:
+ *http://www.cypress.com/?rID=84126
+ *
+ * Copyright (c) 2014 Cypress Semiconductor Corporation.
+ *
+ * Author:
+ * Muthu Mani
+ *
+ * Additional contributors include:
+ *
> -Original Message-
> From: Lee Jones [mailto:lee.jo...@linaro.org]
> Sent: Thursday, October 09, 2014 1:10 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Wolfram Sang; Linus Walleij; Alexandre Courbot;
> gre...@linuxfoundation.org; linux-...@vger.kernel.org; linux-
> g...@v
> -Original Message-
> From: Alexandre Courbot [mailto:gnu...@gmail.com]
> Sent: Tuesday, October 07, 2014 3:34 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Lee Jones; Wolfram Sang; Linus Walleij; Greg Kroah-
> Hartman; linux-...@vger.kernel.org; linux-g...@vger.kern
> -Original Message-
> From: Johan Hovold [mailto:jhov...@gmail.com] On Behalf Of Johan Hovold
> Sent: Monday, October 06, 2014 7:03 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Lee Jones; Wolfram Sang; linux-...@vger.kernel.org; Linus
> Walleij; Alexandre Courbot; linux-g.
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v2:
* Retrieved the i2c transfer status using interrupt in endpoint
* Used kstrtol instead of manually parsing and scnprintf instead of sprintf
* Given i2c adapter device for dev_xxx
* cleaned up
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
Changes since v2:
* Used auto mfd id to support
+++ b/drivers/gpio/gpio-cyusbs23x.c
@@ -0,0 +1,174 @@
+/*
+ * GPIO subdriver for Cypress CYUSBS234 USB-Serial Bridge controller.
+ * Details about the device can be found at:
+ *http://www.cypress.com/?rID=84126
+ *
+ * Copyright (c) 2014 Cypress Semiconductor Corporation.
+ *
+ * Author:
+ * M
ruct platform_device *pdev)
+{
+ struct cyusbs_gpio *cy_gpio = platform_get_drvdata(pdev);
+
+ dev_dbg(&pdev->dev, "%s\n", __func__);
+ gpiochip_remove(&cy_gpio->gpio);
+ return 0;
+}
+
+static struct platform_driver cyusbs23x_gpio_driver = {
+ .driv
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/i2c/busses/Kconfig | 12 +
drivers/i2c/busses/Makefile| 1 +
drivers/i2c/busses/i2c-cyusbs23x.c | 584 +
3 files changed, 597 insertions
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/mfd/Kconfig | 12 +++
drivers
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/mfd/Kconfig | 12 +++
drivers
> -Original Message-
> From: Johan Hovold [mailto:jhov...@gmail.com] On Behalf Of Johan Hovold
> Sent: Monday, September 22, 2014 4:29 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Lee Jones; Wolfram Sang; linux-...@vger.kernel.org; Linus
> Walleij; Alexandre Courbot; linux-g.
Adds support for USB-GPIO interface of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
The GPIO get/set can be done through vendor command on control endpoint.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/i2c/busses/Kconfig | 12 +
drivers/i2c/busses/Makefile| 1 +
drivers/i2c/busses/i2c-cyusbs23x.c | 514 +
3 files changed, 527 insertions
> -Original Message-
> From: Johan Hovold [mailto:jhov...@gmail.com] On Behalf Of Johan Hovold
> Sent: Monday, September 22, 2014 5:14 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Lee Jones; Wolfram Sang; linux-...@vger.kernel.org; Linus
> Walleij; Alexandre Courbot; linux-g.
> -Original Message-
> From: Johan Hovold [mailto:jhov...@gmail.com] On Behalf Of Johan Hovold
> Sent: Monday, September 22, 2014 5:00 PM
> To: Muthu Mani
> Cc: Samuel Ortiz; Lee Jones; Wolfram Sang; linux-...@vger.kernel.org; Linus
> Walleij; Alexandre Courbot; linux-g.
Adds support for USB-GPIO interface of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
The GPIO get/set can be done through vendor command
on control endpoint.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by
Adds support for USB-I2C/GPIO interfaces of Cypress Semiconductor
CYUSBS234 USB-Serial Bridge controller.
Details about the device can be found at:
http://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/mfd/Kconfig | 12
://www.cypress.com/?rID=84126
Signed-off-by: Muthu Mani
Signed-off-by: Rajaram Regupathy
---
drivers/i2c/busses/Kconfig | 12 +
drivers/i2c/busses/Makefile| 1 +
drivers/i2c/busses/i2c-cyusbs23x.c | 534 +
3 files changed, 547 insertions
31 matches
Mail list logo