LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Roger Quadros <rogerq@ti.com>
To: <balbi@ti.com>, <tony@atomide.com>, <myungjoo.ham@samsung.com>,
	<cw00.choi@samsung.com>
Cc: <george.cherian@ti.com>, <nsekhar@ti.com>,
	<devicetree@vger.kernel.org>, <linux-usb@vger.kernel.org>,
	<linux-omap@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	Roger Quadros <rogerq@ti.com>
Subject: [PATCH v2 2/7] usb: extcon: Fix USB-Host cable name
Date: Mon, 26 Jan 2015 14:15:27 +0200	[thread overview]
Message-ID: <1422274532-9488-3-git-send-email-rogerq@ti.com> (raw)
In-Reply-To: <1422274532-9488-1-git-send-email-rogerq@ti.com>

The recommended name for USB-Host cable state is "USB-Host" and not
"USB-HOST" as per drivers/extcon/extcon-class.c extcon_cable_name.

Change all instances of "USB-HOST" to "USB-Host".

Signed-off-by: Roger Quadros <rogerq@ti.com>
Reviewed-by: Felipe Balbi <balbi@ti.com>
Acked-by: Felipe Balbi <balbi@ti.com>
---
 drivers/extcon/extcon-palmas.c | 18 +++++++++---------
 drivers/usb/dwc3/dwc3-omap.c   |  6 +++---
 drivers/usb/phy/phy-omap-otg.c |  4 ++--
 drivers/usb/phy/phy-tahvo.c    |  8 ++++----
 4 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/drivers/extcon/extcon-palmas.c b/drivers/extcon/extcon-palmas.c
index 11c6757..6d002c3 100644
--- a/drivers/extcon/extcon-palmas.c
+++ b/drivers/extcon/extcon-palmas.c
@@ -31,7 +31,7 @@
 
 static const char *palmas_extcon_cable[] = {
 	[0] = "USB",
-	[1] = "USB-HOST",
+	[1] = "USB-Host",
 	NULL,
 };
 
@@ -93,26 +93,26 @@ static irqreturn_t palmas_id_irq_handler(int irq, void *_palmas_usb)
 			PALMAS_USB_ID_INT_LATCH_CLR,
 			PALMAS_USB_ID_INT_EN_HI_CLR_ID_GND);
 		palmas_usb->linkstat = PALMAS_USB_STATE_ID;
-		extcon_set_cable_state(palmas_usb->edev, "USB-HOST", true);
-		dev_info(palmas_usb->dev, "USB-HOST cable is attached\n");
+		extcon_set_cable_state(palmas_usb->edev, "USB-Host", true);
+		dev_info(palmas_usb->dev, "USB-Host cable is attached\n");
 	} else if ((set & PALMAS_USB_ID_INT_SRC_ID_FLOAT) &&
 				(id_src & PALMAS_USB_ID_INT_SRC_ID_FLOAT)) {
 		palmas_write(palmas_usb->palmas, PALMAS_USB_OTG_BASE,
 			PALMAS_USB_ID_INT_LATCH_CLR,
 			PALMAS_USB_ID_INT_EN_HI_CLR_ID_FLOAT);
 		palmas_usb->linkstat = PALMAS_USB_STATE_DISCONNECT;
-		extcon_set_cable_state(palmas_usb->edev, "USB-HOST", false);
-		dev_info(palmas_usb->dev, "USB-HOST cable is detached\n");
+		extcon_set_cable_state(palmas_usb->edev, "USB-Host", false);
+		dev_info(palmas_usb->dev, "USB-Host cable is detached\n");
 	} else if ((palmas_usb->linkstat == PALMAS_USB_STATE_ID) &&
 				(!(set & PALMAS_USB_ID_INT_SRC_ID_GND))) {
 		palmas_usb->linkstat = PALMAS_USB_STATE_DISCONNECT;
-		extcon_set_cable_state(palmas_usb->edev, "USB-HOST", false);
-		dev_info(palmas_usb->dev, "USB-HOST cable is detached\n");
+		extcon_set_cable_state(palmas_usb->edev, "USB-Host", false);
+		dev_info(palmas_usb->dev, "USB-Host cable is detached\n");
 	} else if ((palmas_usb->linkstat == PALMAS_USB_STATE_DISCONNECT) &&
 				(id_src & PALMAS_USB_ID_INT_SRC_ID_GND)) {
 		palmas_usb->linkstat = PALMAS_USB_STATE_ID;
-		extcon_set_cable_state(palmas_usb->edev, "USB-HOST", true);
-		dev_info(palmas_usb->dev, " USB-HOST cable is attached\n");
+		extcon_set_cable_state(palmas_usb->edev, "USB-Host", true);
+		dev_info(palmas_usb->dev, " USB-Host cable is attached\n");
 	}
 
 	return IRQ_HANDLED;
diff --git a/drivers/usb/dwc3/dwc3-omap.c b/drivers/usb/dwc3/dwc3-omap.c
index 172d64e..6713ad9 100644
--- a/drivers/usb/dwc3/dwc3-omap.c
+++ b/drivers/usb/dwc3/dwc3-omap.c
@@ -445,14 +445,14 @@ static int dwc3_omap_extcon_register(struct dwc3_omap *omap)
 
 		omap->id_nb.notifier_call = dwc3_omap_id_notifier;
 		ret = extcon_register_interest(&omap->extcon_id_dev,
-					       edev->name, "USB-HOST",
+					       edev->name, "USB-Host",
 					       &omap->id_nb);
 		if (ret < 0)
-			dev_vdbg(omap->dev, "failed to register notifier for USB-HOST\n");
+			dev_vdbg(omap->dev, "failed to register notifier for USB-Host\n");
 
 		if (extcon_get_cable_state(edev, "USB") == true)
 			dwc3_omap_set_mailbox(omap, OMAP_DWC3_VBUS_VALID);
-		if (extcon_get_cable_state(edev, "USB-HOST") == true)
+		if (extcon_get_cable_state(edev, "USB-Host") == true)
 			dwc3_omap_set_mailbox(omap, OMAP_DWC3_ID_GROUND);
 	}
 
diff --git a/drivers/usb/phy/phy-omap-otg.c b/drivers/usb/phy/phy-omap-otg.c
index 56ee760..53cba3f 100644
--- a/drivers/usb/phy/phy-omap-otg.c
+++ b/drivers/usb/phy/phy-omap-otg.c
@@ -119,7 +119,7 @@ static int omap_otg_probe(struct platform_device *pdev)
 	otg_dev->vbus_nb.notifier_call = omap_otg_vbus_notifier;
 
 	ret = extcon_register_interest(&otg_dev->id_dev, config->extcon,
-				       "USB-HOST", &otg_dev->id_nb);
+				       "USB-Host", &otg_dev->id_nb);
 	if (ret)
 		return ret;
 
@@ -130,7 +130,7 @@ static int omap_otg_probe(struct platform_device *pdev)
 		return ret;
 	}
 
-	otg_dev->id = extcon_get_cable_state(extcon, "USB-HOST");
+	otg_dev->id = extcon_get_cable_state(extcon, "USB-Host");
 	otg_dev->vbus = extcon_get_cable_state(extcon, "USB");
 	omap_otg_set_mode(otg_dev);
 
diff --git a/drivers/usb/phy/phy-tahvo.c b/drivers/usb/phy/phy-tahvo.c
index 845f658..56d3704 100644
--- a/drivers/usb/phy/phy-tahvo.c
+++ b/drivers/usb/phy/phy-tahvo.c
@@ -61,7 +61,7 @@ struct tahvo_usb {
 };
 
 static const char *tahvo_cable[] = {
-	"USB-HOST",
+	"USB-Host",
 	"USB",
 	NULL,
 };
@@ -129,7 +129,7 @@ static void tahvo_usb_become_host(struct tahvo_usb *tu)
 {
 	struct retu_dev *rdev = dev_get_drvdata(tu->pt_dev->dev.parent);
 
-	extcon_set_cable_state(&tu->extcon, "USB-HOST", true);
+	extcon_set_cable_state(&tu->extcon, "USB-Host", true);
 
 	/* Power up the transceiver in USB host mode */
 	retu_write(rdev, TAHVO_REG_USBR, USBR_REGOUT | USBR_NSUSPEND |
@@ -148,7 +148,7 @@ static void tahvo_usb_become_peripheral(struct tahvo_usb *tu)
 {
 	struct retu_dev *rdev = dev_get_drvdata(tu->pt_dev->dev.parent);
 
-	extcon_set_cable_state(&tu->extcon, "USB-HOST", false);
+	extcon_set_cable_state(&tu->extcon, "USB-Host", false);
 
 	/* Power up transceiver and set it in USB peripheral mode */
 	retu_write(rdev, TAHVO_REG_USBR, USBR_SLAVE_CONTROL | USBR_REGOUT |
@@ -376,7 +376,7 @@ static int tahvo_usb_probe(struct platform_device *pdev)
 	}
 
 	/* Set the initial cable state. */
-	extcon_set_cable_state(&tu->extcon, "USB-HOST",
+	extcon_set_cable_state(&tu->extcon, "USB-Host",
 			       tu->tahvo_mode == TAHVO_MODE_HOST);
 	extcon_set_cable_state(&tu->extcon, "USB", tu->vbus_state);
 
-- 
2.1.0


  parent reply	other threads:[~2015-01-26 12:15 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-26 12:15 [PATCH v2 0/7] extcon: usb: Introduce USB GPIO extcon driver. Fix DRA7 & AM57xx USB Roger Quadros
2015-01-26 12:15 ` [PATCH v2 1/7] extcon: usb-gpio: Introduce gpio usb extcon driver Roger Quadros
2015-01-26 13:56   ` Chanwoo Choi
2015-01-26 16:27     ` Roger Quadros
2015-01-27  1:54       ` Chanwoo Choi
2015-01-27 15:38         ` Roger Quadros
2015-01-28  2:19           ` Chanwoo Choi
2015-01-28 12:12             ` Roger Quadros
2015-01-28 17:09               ` Tony Lindgren
2015-01-29 11:31                 ` Roger Quadros
2015-01-29 16:56                   ` Tony Lindgren
2015-01-30 10:58                     ` Roger Quadros
2015-01-28 12:15   ` [PATCH v3 " Roger Quadros
2015-01-29  1:49     ` Chanwoo Choi
2015-01-29 11:26       ` Roger Quadros
2015-01-30  0:06         ` Chanwoo Choi
2015-01-30 11:09           ` Roger Quadros
2015-01-30 13:57             ` Roger Quadros
2015-01-30  0:11     ` Chanwoo Choi
2015-01-30 14:03       ` Roger Quadros
2015-02-02  5:06         ` Chanwoo Choi
2015-02-02 10:21     ` [PATCH v4 1/1] " Roger Quadros
2015-02-03  1:13       ` Chanwoo Choi
2015-03-16 12:32       ` Ivan T. Ivanov
2015-03-16 13:11         ` Roger Quadros
2015-03-16 14:23           ` Ivan T. Ivanov
2015-03-17  2:01             ` Chanwoo Choi
2015-03-17  7:52               ` Ivan T. Ivanov
2015-03-17  8:00                 ` Ivan T. Ivanov
2015-01-26 12:15 ` Roger Quadros [this message]
2015-01-30 11:04   ` [PATCH v2 2/7] usb: extcon: Fix USB-Host cable name Roger Quadros
2015-01-30 14:05     ` Roger Quadros
2015-02-02  5:04       ` Chanwoo Choi
2015-02-02  9:09         ` Roger Quadros
2015-02-02  9:55           ` Chanwoo Choi
2015-02-02 10:01             ` Roger Quadros
2015-02-02 10:06               ` Chanwoo Choi
2015-01-26 12:15 ` [PATCH v2 3/7] ARM: dts: dra7-evm: Add extcon nodes for USB Roger Quadros
2015-01-26 12:15 ` [PATCH v2 4/7] ARM: dts: dra72-evm: " Roger Quadros
2015-01-26 12:15 ` [PATCH v2 5/7] ARM: dts: am57xx-beagle-x15: " Roger Quadros
2015-01-26 12:15 ` [PATCH v2 6/7] ARM: dts: am57xx-beagle-x15: Fix USB2 mode Roger Quadros
2015-01-26 12:15 ` [PATCH v2 7/7] ARM: omap2plus_defconfig: Enable EXTCON_GPIO_USB Roger Quadros
2015-03-16 17:53   ` Tony Lindgren
2015-03-17  9:29     ` Roger Quadros

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=1422274532-9488-3-git-send-email-rogerq@ti.com \
    --to=rogerq@ti.com \
    --cc=balbi@ti.com \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=george.cherian@ti.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=myungjoo.ham@samsung.com \
    --cc=nsekhar@ti.com \
    --cc=tony@atomide.com \
    --subject='Re: [PATCH v2 2/7] usb: extcon: Fix USB-Host cable name' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).