linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2
@ 2014-05-29 13:16 Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support Magnus Damm
                   ` (3 more replies)
  0 siblings, 4 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:16 UTC (permalink / raw)
  To: linux-kernel
  Cc: devel, linux-sh, gregkh, horms, geert, laurent.pinchart, olof,
	Magnus Damm, dan.carpenter

staging: Emma Mobile USB driver and KZM9D board code V2

[PATCH v2 01/05] staging: emxx_udc: Add Emma Mobile USB Gadget driver
[PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support
[PATCH v2 03/05] staging: emxx_udc: Add TODO file
[PATCH v2 04/05] staging: board: Initial board staging support
[PATCH v2 05/05] staging: board: kzm9d: Board staging support for emxx_udc

This patch series is V2 of the old USB Gadget driver for Emma Mobile
that gets slightly adjusted to make use of the platform device interface
which in turn is used to add USB Gadget support to the KZM9D board.

Two separate staging components are included in this series:
1) the emxx_udc driver - from out-of-tree Android 2.6.35.7
2) board staging support for KZM9D - platform device for DT-only KZM9D

The two components above will be used to continously improve the driver
and board integration code until the driver can be moved out of staging
and/or DT bindings are available so the board staging platform device code
can be replaced with a DT node.

A few minor things have happened since V1:
- Added TODO file for emxx_udc
- Broke out board staging base support, included TODO file
- Added code to avoid registering platform device if DT node exists
- Modified KZM9D board code build condition to use SoC Kconfig entry

Many thanks to Dan Carpenter, Geert Uytterhoeven and Greg KH for
feedback!

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Written against renesas-devel-v3.15-rc7-20140528

 drivers/staging/Kconfig             |    4 
 drivers/staging/Makefile            |    2 
 drivers/staging/board/Kconfig       |    7 
 drivers/staging/board/Makefile      |    2 
 drivers/staging/board/TODO          |    2 
 drivers/staging/board/board.c       |   41 
 drivers/staging/board/board.h       |   20 
 drivers/staging/board/kzm9d.c       |   19 
 drivers/staging/emxx_udc/Kconfig    |   10 
 drivers/staging/emxx_udc/Makefile   |    1 
 drivers/staging/emxx_udc/TODO       |    4 
 drivers/staging/emxx_udc/emxx_udc.c | 3616 ++++++++++++++++++++++++++++++++++-
 drivers/staging/emxx_udc/emxx_udc.h |  671 ++++++
 13 files changed, 4351 insertions(+), 48 deletions(-)

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support
  2014-05-29 13:16 [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2 Magnus Damm
@ 2014-05-29 13:17 ` Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 03/05] staging: emxx_udc: Add TODO file Magnus Damm
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:17 UTC (permalink / raw)
  To: linux-kernel
  Cc: devel, linux-sh, gregkh, horms, geert, laurent.pinchart, olof,
	Magnus Damm, dan.carpenter

From: Magnus Damm <damm+renesas@opensource.se>

Adjust the emxx_udc driver to make use of the standard
driver model to pass I/O memory and IRQ as resources
instead of hard coding those things in the driver.

Needs more work - the VBUS signal is yet not handled.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V1:
 - None

 drivers/staging/emxx_udc/emxx_udc.c |   57 +++++++++++------------------------
 drivers/staging/emxx_udc/emxx_udc.h |    9 -----
 2 files changed, 18 insertions(+), 48 deletions(-)

--- 0002/drivers/staging/emxx_udc/emxx_udc.c
+++ work/drivers/staging/emxx_udc/emxx_udc.c	2014-05-22 16:20:02.000000000 +0900
@@ -3356,37 +3356,38 @@ static int nbu2ss_drv_probe(struct platf
 {
 	int	status = -ENODEV;
 	struct nbu2ss_udc	*udc;
+	struct resource *r;
+	int irq;
+	void __iomem *mmio_base;
 
 	udc = &udc_controller;
 	memset(udc, 0, sizeof(struct nbu2ss_udc));
 
 	platform_set_drvdata(pdev, udc);
 
-	/* IO Memory Region */
-	if (!request_mem_region(USB_BASE_ADDRESS, USB_BASE_SIZE
-				, driver_name)) {
+	/* require I/O memory and IRQ to be provided as resources */
+	r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+	mmio_base = devm_request_and_ioremap(&pdev->dev, r);
+	if (IS_ERR(mmio_base)) {
+		dev_err(&pdev->dev, "failed to map I/O memory\n");
+		return PTR_ERR(mmio_base);
+	}
 
-		ERR("request_mem_region failed\n");
-		return -EBUSY;
+	irq = platform_get_irq(pdev, 0);
+	if (irq < 0) {
+		dev_err(&pdev->dev, "failed to get IRQ\n");
+		return irq;
 	}
+	status = devm_request_irq(&pdev->dev, irq, _nbu2ss_udc_irq,
+				  0, driver_name, udc);
 
 	/* IO Memory */
-	udc->p_regs = (PT_FC_REGS)ioremap(USB_BASE_ADDRESS, USB_BASE_SIZE);
-	if (!udc->p_regs) {
-		ERR("request_io_mem failed\n");
-		goto cleanup3;
-	}
+	udc->p_regs = (PT_FC_REGS)mmio_base;
 
 	/* USB Function Controller Interrupt */
-	status = request_irq(USB_UDC_IRQ_1,
-				_nbu2ss_udc_irq,
-				IRQF_DISABLED,
-				driver_name,
-				udc);
-
 	if (status != 0) {
 		ERR("request_irq(USB_UDC_IRQ_1) failed\n");
-		goto cleanup2;
+		goto cleanup1;
 	}
 
 	/* Driver Initialization */
@@ -3412,18 +3413,6 @@ static int nbu2ss_drv_probe(struct platf
 	return status;
 
 cleanup1:
-	/* Interrupt Handler - Release */
-	free_irq(USB_UDC_IRQ_1, udc);
-
-cleanup2:
-	/* IO Memory - Release */
-	if (udc->p_regs)
-		iounmap(udc->p_regs);
-
-cleanup3:
-	/* IO Memory Region - Release */
-	release_mem_region(USB_BASE_ADDRESS, USB_BASE_SIZE);
-
 	return status;
 }
 
@@ -3456,18 +3445,8 @@ static int __exit nbu2ss_drv_remove(stru
 	}
 
 	/* Interrupt Handler - Release */
-	free_irq(USB_UDC_IRQ_1, udc);
-
-	/* Interrupt Handler - Release */
 	free_irq(INT_VBUS, udc);
 
-	/* IO Memory - Release */
-	if (udc->p_regs)
-		iounmap(udc->p_regs);
-
-	/* IO Memory Region - Release */
-	release_mem_region(USB_BASE_ADDRESS, USB_BASE_SIZE);
-
 	return 0;
 }
 
--- 0002/drivers/staging/emxx_udc/emxx_udc.h
+++ work/drivers/staging/emxx_udc/emxx_udc.h	2014-05-22 16:20:02.000000000 +0900
@@ -47,20 +47,11 @@
 
 
 /*------------ Board dependence(Resource) */
-#define USB_BASE_ADDRESS	EMXX_USBS1_BASE
-#define USB_BASE_SIZE		0x2000
-
-#define USB_UDC_IRQ_0		INT_USBF0
-#define USB_UDC_IRQ_1		INT_USBF1
 #define	VBUS_VALUE		GPIO_VBUS
 
 /* below hacked up for staging integration */
 #define GPIO_VBUS 0 /* GPIO_P153 on KZM9D */
 #define INT_VBUS 0 /* IRQ for GPIO_P153 */
-#define INT_USBF0 158
-#define INT_USBF1 159
-#define EMXX_USBS0_BASE 0xe2700000
-#define EMXX_USBS1_BASE 0xe2800000
 
 /*------------ Board dependence(Wait) */
 

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH v2 03/05] staging: emxx_udc: Add TODO file
  2014-05-29 13:16 [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2 Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support Magnus Damm
@ 2014-05-29 13:17 ` Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 04/05] staging: board: Initial board staging support Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 05/05] staging: board: kzm9d: Board staging support for emxx_udc Magnus Damm
  3 siblings, 0 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:17 UTC (permalink / raw)
  To: linux-kernel
  Cc: devel, linux-sh, gregkh, horms, geert, laurent.pinchart, olof,
	Magnus Damm, dan.carpenter

From: Magnus Damm <damm+renesas@opensource.se>

Add a TODO file for emxx_udc to show what is left to do.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V1:
 - New patch

 drivers/staging/emxx_udc/TODO |    4 ++++
 1 file changed, 4 insertions(+)

--- /dev/null
+++ work/drivers/staging/emxx_udc/TODO	2014-05-29 18:08:58.000000000 +0900
@@ -0,0 +1,4 @@
+* add clock framework support (platform device with CCF needs special care)
+* break out board-specific VBUS GPIO to work with multiplatform
+* DT bindings
+* move driver into drivers/usb/gadget/

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:16 [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2 Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support Magnus Damm
  2014-05-29 13:17 ` [PATCH v2 03/05] staging: emxx_udc: Add TODO file Magnus Damm
@ 2014-05-29 13:17 ` Magnus Damm
  2014-05-29 13:20   ` Dan Carpenter
  2014-05-29 13:17 ` [PATCH v2 05/05] staging: board: kzm9d: Board staging support for emxx_udc Magnus Damm
  3 siblings, 1 reply; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:17 UTC (permalink / raw)
  To: linux-kernel
  Cc: devel, linux-sh, gregkh, horms, geert, laurent.pinchart, olof,
	Magnus Damm, dan.carpenter

From: Magnus Damm <damm+renesas@opensource.se>

Add staging board base support to allow continuous upstream
in-tree development and integration of platform devices.

Helps developers integrate devices as platform devices for
device drivers that only provide platform device bindings.
This in turn allows for incremental development of both
hardware feature support and DT binding work in parallel.

Two separate pieces of board staging functionality is
provided to ease per-board staging board support:
 - The board_staging() macro allows easy per-board callbacks
 - The board_staging_dt_node_available() provides DT node checking

Tested on the KZM9D board with the emxx_udc staging driver.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V1:
 - New broken out staging board base support
 - Added the function board_staging_dt_node_available()
 - Added a TODO file

 drivers/staging/Kconfig        |    2 +
 drivers/staging/Makefile       |    1 
 drivers/staging/board/Kconfig  |    7 ++++++
 drivers/staging/board/Makefile |    1 
 drivers/staging/board/TODO     |    2 +
 drivers/staging/board/board.c  |   41 ++++++++++++++++++++++++++++++++++++++++
 drivers/staging/board/board.h  |   20 +++++++++++++++++++
 7 files changed, 74 insertions(+)

--- 0008/drivers/staging/Kconfig
+++ work/drivers/staging/Kconfig	2014-05-29 21:40:40.000000000 +0900
@@ -112,6 +112,8 @@ source "drivers/staging/media/Kconfig"
 
 source "drivers/staging/android/Kconfig"
 
+source "drivers/staging/board/Kconfig"
+
 source "drivers/staging/ozwpan/Kconfig"
 
 source "drivers/staging/gdm72xx/Kconfig"
--- 0008/drivers/staging/Makefile
+++ work/drivers/staging/Makefile	2014-05-29 21:40:40.000000000 +0900
@@ -49,6 +49,7 @@ obj-$(CONFIG_TOUCHSCREEN_CLEARPAD_TM1217
 obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_I2C_RMI4)	+= ste_rmi4/
 obj-$(CONFIG_MFD_NVEC)		+= nvec/
 obj-$(CONFIG_ANDROID)		+= android/
+obj-$(CONFIG_STAGING_BOARD)	+= board/
 obj-$(CONFIG_USB_WPAN_HCD)	+= ozwpan/
 obj-$(CONFIG_WIMAX_GDM72XX)	+= gdm72xx/
 obj-$(CONFIG_LTE_GDM724X)	+= gdm724x/
--- /dev/null
+++ work/drivers/staging/board/Kconfig	2014-05-29 21:40:41.000000000 +0900
@@ -0,0 +1,7 @@
+config STAGING_BOARD
+	boolean "Staging Board Support"
+	help
+	  Select to enable per-board staging support code.
+
+	  If in doubt, say N here.
+
--- /dev/null
+++ work/drivers/staging/board/Makefile	2014-05-29 21:40:41.000000000 +0900
@@ -0,0 +1 @@
+obj-y	:= board.o
--- /dev/null
+++ work/drivers/staging/board/TODO	2014-05-29 21:40:41.000000000 +0900
@@ -0,0 +1,2 @@
+* replace platform device code with DT nodes once the driver supports DT
+* remove staging board code when no more platform devices are needed
--- /dev/null
+++ work/drivers/staging/board/board.c	2014-05-29 21:46:32.000000000 +0900
@@ -0,0 +1,41 @@
+#include <linux/init.h>
+#include <linux/device.h>
+#include <linux/kernel.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
+#include "board.h"
+
+static bool find_by_address(u64 base_address)
+{
+	struct device_node *dn = of_find_all_nodes(NULL);
+	struct resource res;
+
+	while (dn) {
+		if (of_can_translate_address(dn)
+		    && !of_address_to_resource(dn, 0, &res)) {
+			if (res.start = base_address) {
+				of_node_put(dn);
+				return true;
+			}
+		}
+		dn = of_find_all_nodes(dn);
+	}
+
+	return false;
+}
+
+bool __init board_staging_dt_node_available(const struct resource *resource,
+					    unsigned int num_resources)
+{
+	unsigned int i;
+
+	for (i = 0; i < num_resources; i++) {
+		const struct resource *r = resource + i;
+
+		if (resource_type(r) = IORESOURCE_MEM)
+			if (find_by_address(r->start))
+				return true; /* DT node available */
+	}
+
+	return false; /* Nothing found */
+}
--- /dev/null
+++ work/drivers/staging/board/board.h	2014-05-29 21:40:41.000000000 +0900
@@ -0,0 +1,20 @@
+#ifndef __BOARD_H__
+#define __BOARD_H__
+#include <linux/init.h>
+#include <linux/of.h>
+
+bool board_staging_dt_node_available(const struct resource *resource,
+				     unsigned int num_resources);
+
+#define board_staging(str, fn)			\
+static int __init runtime_board_check(void)	\
+{						\
+	if (of_machine_is_compatible(str))	\
+		fn();				\
+						\
+	return 0;				\
+}						\
+						\
+late_initcall(runtime_board_check)
+
+#endif /* __BOARD_H__ */

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH v2 05/05] staging: board: kzm9d: Board staging support for emxx_udc
  2014-05-29 13:16 [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2 Magnus Damm
                   ` (2 preceding siblings ...)
  2014-05-29 13:17 ` [PATCH v2 04/05] staging: board: Initial board staging support Magnus Damm
@ 2014-05-29 13:17 ` Magnus Damm
  3 siblings, 0 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:17 UTC (permalink / raw)
  To: linux-kernel
  Cc: devel, linux-sh, gregkh, horms, geert, laurent.pinchart, olof,
	Magnus Damm, dan.carpenter

From: Magnus Damm <damm+renesas@opensource.se>

Add staging board support for the KZM9D board and add
an emxx_udc platform device to allow in-tree continous 
development of the driver on the KZM9D board.

When DT bindings are ready for the emxx_udc driver then
the platform device in the KZM9D staging board code can
easily be removed. Until then we use platform devices
to continously improve the driver and integration code.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes since V1:
 - Broke out staging board base patch
 - Compile in if CONFIG_ARCH_EMEV2 is selected
 - Make use of board_staging_dt_node_available()

 drivers/staging/board/Makefile |    1 +
 drivers/staging/board/kzm9d.c  |   19 +++++++++++++++++++
 2 files changed, 20 insertions(+)

--- 0011/drivers/staging/board/Makefile
+++ work/drivers/staging/board/Makefile	2014-05-29 21:40:49.000000000 +0900
@@ -1 +1,2 @@
 obj-y	:= board.o
+obj-$(CONFIG_ARCH_EMEV2)      += kzm9d.o
--- /dev/null
+++ work/drivers/staging/board/kzm9d.c	2014-05-29 21:42:34.000000000 +0900
@@ -0,0 +1,19 @@
+/* Staging board support for KZM9D. Enable not-yet-DT-capable devices here. */
+
+#include <linux/kernel.h>
+#include <linux/platform_device.h>
+#include "board.h"
+
+static const struct resource usbs1_res[] __initconst = {
+	DEFINE_RES_MEM(0xe2800000, 0x2000),
+	DEFINE_RES_IRQ(159),
+};
+
+static void __init kzm9d_init(void)
+{
+	if (!board_staging_dt_node_available(usbs1_res, ARRAY_SIZE(usbs1_res)))
+		platform_device_register_simple("emxx_udc", -1, usbs1_res,
+						ARRAY_SIZE(usbs1_res));
+}
+
+board_staging("renesas,kzm9d", kzm9d_init);

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:17 ` [PATCH v2 04/05] staging: board: Initial board staging support Magnus Damm
@ 2014-05-29 13:20   ` Dan Carpenter
  2014-05-29 13:27     ` Magnus Damm
  0 siblings, 1 reply; 13+ messages in thread
From: Dan Carpenter @ 2014-05-29 13:20 UTC (permalink / raw)
  To: Magnus Damm
  Cc: linux-kernel, devel, linux-sh, gregkh, horms, geert,
	laurent.pinchart, olof

On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
> --- /dev/null
> +++ work/drivers/staging/board/Kconfig	2014-05-29 21:40:41.000000000 +0900
> @@ -0,0 +1,7 @@
> +config STAGING_BOARD
> +	boolean "Staging Board Support"
> +	help
> +	  Select to enable per-board staging support code.
> +
> +	  If in doubt, say N here.
> +

Actually, you're probably going to need to add a bunch of dependencies
here or it will break "make randconfig" right away.  Sorry that I forgot
about this in the first review.

regards,
dan carpenter


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:20   ` Dan Carpenter
@ 2014-05-29 13:27     ` Magnus Damm
  2014-05-29 13:53       ` Magnus Damm
  2014-05-29 23:10       ` Simon Horman
  0 siblings, 2 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:27 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: linux-kernel, devel, SH-Linux, Greg KH, Simon Horman [Horms],
	Geert Uytterhoeven, Laurent Pinchart, Olof Johansson

Hi Dan,

On Thu, May 29, 2014 at 10:20 PM, Dan Carpenter
<dan.carpenter@oracle.com> wrote:
> On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
>> --- /dev/null
>> +++ work/drivers/staging/board/Kconfig        2014-05-29 21:40:41.000000000 +0900
>> @@ -0,0 +1,7 @@
>> +config STAGING_BOARD
>> +     boolean "Staging Board Support"
>> +     help
>> +       Select to enable per-board staging support code.
>> +
>> +       If in doubt, say N here.
>> +
>
> Actually, you're probably going to need to add a bunch of dependencies
> here or it will break "make randconfig" right away.  Sorry that I forgot
> about this in the first review.

Good point, thanks for checking. I will have a look at this and add
dependencies to make sure it builds on a wide range of platforms.

Regarding the emxx_udc portion of the patches (in the v2 series patch
1 -> 3), if there are no objections would it be possible for you to
take them as-is? If so I'll resend the staging board bits only.

Thanks!

/ magnus

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:27     ` Magnus Damm
@ 2014-05-29 13:53       ` Magnus Damm
  2014-05-29 14:03         ` Paul Bolle
  2014-05-29 23:10       ` Simon Horman
  1 sibling, 1 reply; 13+ messages in thread
From: Magnus Damm @ 2014-05-29 13:53 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: linux-kernel, devel, SH-Linux, Greg KH, Simon Horman [Horms],
	Geert Uytterhoeven, Laurent Pinchart, Olof Johansson

On Thu, May 29, 2014 at 10:27 PM, Magnus Damm <magnus.damm@gmail.com> wrote:
> Hi Dan,
>
> On Thu, May 29, 2014 at 10:20 PM, Dan Carpenter
> <dan.carpenter@oracle.com> wrote:
>> On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
>>> --- /dev/null
>>> +++ work/drivers/staging/board/Kconfig        2014-05-29 21:40:41.000000000 +0900
>>> @@ -0,0 +1,7 @@
>>> +config STAGING_BOARD
>>> +     boolean "Staging Board Support"
>>> +     help
>>> +       Select to enable per-board staging support code.
>>> +
>>> +       If in doubt, say N here.
>>> +
>>
>> Actually, you're probably going to need to add a bunch of dependencies
>> here or it will break "make randconfig" right away.  Sorry that I forgot
>> about this in the first review.
>
> Good point, thanks for checking. I will have a look at this and add
> dependencies to make sure it builds on a wide range of platforms.

To begin with, this hunk fixes the i386_defconfig + staging board build.

--- 0011/drivers/staging/board/Kconfig
+++ work/drivers/staging/board/Kconfig    2014-05-29 22:32:39.000000000 +0900
@@ -1,5 +1,6 @@
 config STAGING_BOARD
     boolean "Staging Board Support"
+    depends on OF && OF_ADDRESS
     help
       Select to enable per-board staging support code.

Actually, there are not many dependencies - I believe the OF bits is about it.

Cheers,

/ magnus

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:53       ` Magnus Damm
@ 2014-05-29 14:03         ` Paul Bolle
  2014-05-30  6:23           ` Magnus Damm
  0 siblings, 1 reply; 13+ messages in thread
From: Paul Bolle @ 2014-05-29 14:03 UTC (permalink / raw)
  To: Magnus Damm
  Cc: Dan Carpenter, linux-kernel, devel, SH-Linux, Greg KH,
	Simon Horman [Horms], Geert Uytterhoeven, Laurent Pinchart,
	Olof Johansson

On Thu, 2014-05-29 at 22:53 +0900, Magnus Damm wrote:
> --- 0011/drivers/staging/board/Kconfig
> +++ work/drivers/staging/board/Kconfig    2014-05-29 22:32:39.000000000 +0900
> @@ -1,5 +1,6 @@
>  config STAGING_BOARD
>      boolean "Staging Board Support"
> +    depends on OF && OF_ADDRESS

I have no idea what this is all about, but wouldn't just OF_ADDRESS be
enough here (as OF_ADDRESS depends on OF)?

>      help
>        Select to enable per-board staging support code.
> 
> Actually, there are not many dependencies - I believe the OF bits is about it.


Paul Bolle


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 13:27     ` Magnus Damm
  2014-05-29 13:53       ` Magnus Damm
@ 2014-05-29 23:10       ` Simon Horman
  2014-06-06 12:07         ` Magnus Damm
  1 sibling, 1 reply; 13+ messages in thread
From: Simon Horman @ 2014-05-29 23:10 UTC (permalink / raw)
  To: Magnus Damm
  Cc: Dan Carpenter, linux-kernel, devel, SH-Linux, Greg KH,
	Geert Uytterhoeven, Laurent Pinchart, Olof Johansson

On Thu, May 29, 2014 at 10:27:30PM +0900, Magnus Damm wrote:
> Hi Dan,
> 
> On Thu, May 29, 2014 at 10:20 PM, Dan Carpenter
> <dan.carpenter@oracle.com> wrote:
> > On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
> >> --- /dev/null
> >> +++ work/drivers/staging/board/Kconfig        2014-05-29 21:40:41.000000000 +0900
> >> @@ -0,0 +1,7 @@
> >> +config STAGING_BOARD
> >> +     boolean "Staging Board Support"
> >> +     help
> >> +       Select to enable per-board staging support code.
> >> +
> >> +       If in doubt, say N here.
> >> +
> >
> > Actually, you're probably going to need to add a bunch of dependencies
> > here or it will break "make randconfig" right away.  Sorry that I forgot
> > about this in the first review.
> 
> Good point, thanks for checking. I will have a look at this and add
> dependencies to make sure it builds on a wide range of platforms.

Hi Magnus,

let me know if you would like me to perform some build-testing.

> Regarding the emxx_udc portion of the patches (in the v2 series patch
> 1 -> 3), if there are no objections would it be possible for you to
> take them as-is? If so I'll resend the staging board bits only.
> 
> Thanks!
> 
> / magnus
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 14:03         ` Paul Bolle
@ 2014-05-30  6:23           ` Magnus Damm
  0 siblings, 0 replies; 13+ messages in thread
From: Magnus Damm @ 2014-05-30  6:23 UTC (permalink / raw)
  To: Paul Bolle
  Cc: Dan Carpenter, linux-kernel, devel, SH-Linux, Greg KH,
	Simon Horman [Horms], Geert Uytterhoeven, Laurent Pinchart,
	Olof Johansson

On Thu, May 29, 2014 at 11:03 PM, Paul Bolle <pebolle@tiscali.nl> wrote:
> On Thu, 2014-05-29 at 22:53 +0900, Magnus Damm wrote:
>> --- 0011/drivers/staging/board/Kconfig
>> +++ work/drivers/staging/board/Kconfig    2014-05-29 22:32:39.000000000 +0900
>> @@ -1,5 +1,6 @@
>>  config STAGING_BOARD
>>      boolean "Staging Board Support"
>> +    depends on OF && OF_ADDRESS
>
> I have no idea what this is all about, but wouldn't just OF_ADDRESS be
> enough here (as OF_ADDRESS depends on OF)?

Yeah, that makes sense. I am also considering stubbing in the missing
function prototypes in the header files to be able to get rid of this
dependency.

Cheers,

/ magnus

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-05-29 23:10       ` Simon Horman
@ 2014-06-06 12:07         ` Magnus Damm
  2014-06-10  1:56           ` Simon Horman
  0 siblings, 1 reply; 13+ messages in thread
From: Magnus Damm @ 2014-06-06 12:07 UTC (permalink / raw)
  To: Simon Horman
  Cc: Dan Carpenter, linux-kernel, devel, SH-Linux, Greg KH,
	Geert Uytterhoeven, Laurent Pinchart, Olof Johansson

On Fri, May 30, 2014 at 8:10 AM, Simon Horman <horms@verge.net.au> wrote:
> On Thu, May 29, 2014 at 10:27:30PM +0900, Magnus Damm wrote:
>> Hi Dan,
>>
>> On Thu, May 29, 2014 at 10:20 PM, Dan Carpenter
>> <dan.carpenter@oracle.com> wrote:
>> > On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
>> >> --- /dev/null
>> >> +++ work/drivers/staging/board/Kconfig        2014-05-29 21:40:41.000000000 +0900
>> >> @@ -0,0 +1,7 @@
>> >> +config STAGING_BOARD
>> >> +     boolean "Staging Board Support"
>> >> +     help
>> >> +       Select to enable per-board staging support code.
>> >> +
>> >> +       If in doubt, say N here.
>> >> +
>> >
>> > Actually, you're probably going to need to add a bunch of dependencies
>> > here or it will break "make randconfig" right away.  Sorry that I forgot
>> > about this in the first review.
>>
>> Good point, thanks for checking. I will have a look at this and add
>> dependencies to make sure it builds on a wide range of platforms.
>
> Hi Magnus,
>
> let me know if you would like me to perform some build-testing.

Hey Simon,

Thanks for the offer. When you have time, can you please feed V3 into
your build test setup?

[PATCH v3 00/05] staging: Emma Mobile USB driver and KZM9D board code V3
[PATCH v3 01/05] staging: emxx_udc: Add Emma Mobile USB Gadget driver
[PATCH v3 02/05] staging: emxx_udc: I/O memory and IRQ resource support
[PATCH v3 03/05] staging: emxx_udc: Add TODO file
[PATCH v3 04/05] staging: board: Initial board staging support
[PATCH v3 05/05] staging: board: kzm9d: Board staging support for emxx_udc

Cheers,

/ magnus

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH v2 04/05] staging: board: Initial board staging support
  2014-06-06 12:07         ` Magnus Damm
@ 2014-06-10  1:56           ` Simon Horman
  0 siblings, 0 replies; 13+ messages in thread
From: Simon Horman @ 2014-06-10  1:56 UTC (permalink / raw)
  To: Magnus Damm
  Cc: Dan Carpenter, linux-kernel, devel, SH-Linux, Greg KH,
	Geert Uytterhoeven, Laurent Pinchart, Olof Johansson

On Fri, Jun 06, 2014 at 09:07:44PM +0900, Magnus Damm wrote:
> On Fri, May 30, 2014 at 8:10 AM, Simon Horman <horms@verge.net.au> wrote:
> > On Thu, May 29, 2014 at 10:27:30PM +0900, Magnus Damm wrote:
> >> Hi Dan,
> >>
> >> On Thu, May 29, 2014 at 10:20 PM, Dan Carpenter
> >> <dan.carpenter@oracle.com> wrote:
> >> > On Thu, May 29, 2014 at 10:17:32PM +0900, Magnus Damm wrote:
> >> >> --- /dev/null
> >> >> +++ work/drivers/staging/board/Kconfig        2014-05-29 21:40:41.000000000 +0900
> >> >> @@ -0,0 +1,7 @@
> >> >> +config STAGING_BOARD
> >> >> +     boolean "Staging Board Support"
> >> >> +     help
> >> >> +       Select to enable per-board staging support code.
> >> >> +
> >> >> +       If in doubt, say N here.
> >> >> +
> >> >
> >> > Actually, you're probably going to need to add a bunch of dependencies
> >> > here or it will break "make randconfig" right away.  Sorry that I forgot
> >> > about this in the first review.
> >>
> >> Good point, thanks for checking. I will have a look at this and add
> >> dependencies to make sure it builds on a wide range of platforms.
> >
> > Hi Magnus,
> >
> > let me know if you would like me to perform some build-testing.
> 
> Hey Simon,
> 
> Thanks for the offer. When you have time, can you please feed V3 into
> your build test setup?
> 
> [PATCH v3 00/05] staging: Emma Mobile USB driver and KZM9D board code V3
> [PATCH v3 01/05] staging: emxx_udc: Add Emma Mobile USB Gadget driver
> [PATCH v3 02/05] staging: emxx_udc: I/O memory and IRQ resource support
> [PATCH v3 03/05] staging: emxx_udc: Add TODO file
> [PATCH v3 04/05] staging: board: Initial board staging support
> [PATCH v3 05/05] staging: board: kzm9d: Board staging support for emxx_udc

Hi Magnus,

my test was less exciting as I had hoped as STAGING is not widely
enabled in defconfigs.

I compiled v3.15-rc8 with the patches above applied using
the defconfigs and allmodconfigs for a wide range of architectures.
The result was that all of the configs that built for v3.15-rc8
also built with your patches applied.

In other words, I did not find a problem.

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2014-06-10  1:56 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-29 13:16 [PATCH v2 00/05] staging: Emma Mobile USB driver and KZM9D board code V2 Magnus Damm
2014-05-29 13:17 ` [PATCH v2 02/05] staging: emxx_udc: I/O memory and IRQ resource support Magnus Damm
2014-05-29 13:17 ` [PATCH v2 03/05] staging: emxx_udc: Add TODO file Magnus Damm
2014-05-29 13:17 ` [PATCH v2 04/05] staging: board: Initial board staging support Magnus Damm
2014-05-29 13:20   ` Dan Carpenter
2014-05-29 13:27     ` Magnus Damm
2014-05-29 13:53       ` Magnus Damm
2014-05-29 14:03         ` Paul Bolle
2014-05-30  6:23           ` Magnus Damm
2014-05-29 23:10       ` Simon Horman
2014-06-06 12:07         ` Magnus Damm
2014-06-10  1:56           ` Simon Horman
2014-05-29 13:17 ` [PATCH v2 05/05] staging: board: kzm9d: Board staging support for emxx_udc Magnus Damm

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).