Re: [PATCH] arm: aspeed: Add Aspeed board file with clocksource devicetree fixup

2017-06-20 Thread Jonas Jensen
On 20 June 2017 at 10:06, Linus Walleij wrote: > Moxart is deploying the DTBs with the kernel, they go hand-in-hand. > Backward compatibility with old DTBs here would just be an academic > exercise. I've used CONFIG_ARM_APPENDED_DTB=y since the beginning mainly because

Re: [PATCH] arm: aspeed: Add Aspeed board file with clocksource devicetree fixup

2017-06-20 Thread Jonas Jensen
On 20 June 2017 at 10:06, Linus Walleij wrote: > Moxart is deploying the DTBs with the kernel, they go hand-in-hand. > Backward compatibility with old DTBs here would just be an academic > exercise. I've used CONFIG_ARM_APPENDED_DTB=y since the beginning mainly because UC-7112-LX's proprietary

Re: [PATCH 2/2] drivers/clocksource/fttmr010: Implement delay timer

2017-06-12 Thread Jonas Jensen
4 ofpart partitions found on MTD device 8000.flash [1.192166] Creating 4 MTD partitions on "8000.flash": [1.198093] 0x-0x0004 : "bootloader" [1.220088] 0x0004-0x0020 : "linux kernel" [ 1.244496] 0x0020-0x00a0 : "root filesystem" [1.269177] 0x00a0-0x0100 : "user filesystem" Tested-by: Jonas Jensen <jonas.jen...@gmail.com>

Re: [PATCH 2/2] drivers/clocksource/fttmr010: Implement delay timer

2017-06-12 Thread Jonas Jensen
ce 8000.flash [1.192166] Creating 4 MTD partitions on "8000.flash": [1.198093] 0x-0x0004 : "bootloader" [1.220088] 0x0004-0x0020 : "linux kernel" [ 1.244496] 0x0020-0x00a0 : "root filesystem" [1.269177] 0x00a0-0x0100 : "user filesystem" Tested-by: Jonas Jensen

[PATCH] ARM: dts: moxart: rename sdhci mmc

2017-05-23 Thread Jonas Jensen
The host driver compatible string changed to "moxa,moxart-mmc" during the review process while the old name was committed to moxart's dts* files. Correct the host driver compatible string and also fix the node name. Signed-off-by: Jonas Jensen <jonas.jen...@gmail.com> --- No

[PATCH] ARM: dts: moxart: rename sdhci mmc

2017-05-23 Thread Jonas Jensen
The host driver compatible string changed to "moxa,moxart-mmc" during the review process while the old name was committed to moxart's dts* files. Correct the host driver compatible string and also fix the node name. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20170518

Re: [PATCH 7/8 v2] clocksource/drivers/fttmr010: Merge Moxa into FTTMR010

2017-05-19 Thread Jonas Jensen
XT4-fs (mmcblk0p1): mounted filesystem with ordered data mode. Opts: (null) [6.265796] VFS: Mounted root (ext3 filesystem) on device 179:1. [6.373316] devtmpfs: mounted [6.410728] Freeing unused kernel memory: 192K [6.415430] This architecture does not have kernel memory protection. IN

Re: [PATCH 7/8 v2] clocksource/drivers/fttmr010: Merge Moxa into FTTMR010

2017-05-19 Thread Jonas Jensen
tem with ordered data mode. Opts: (null) [6.265796] VFS: Mounted root (ext3 filesystem) on device 179:1. [6.373316] devtmpfs: mounted [6.410728] Freeing unused kernel memory: 192K [6.415430] This architecture does not have kernel memory protection. INIT: version 2.88 booting Tested-by: Jonas Jensen Jonas

Re: [PATCH 0/8] clocksource: Generalize Faraday timer

2017-05-18 Thread Jonas Jensen
On 17 May 2017 at 16:05, Linus Walleij <linus.wall...@linaro.org> wrote: > The patches can be applied as soon as Jonas Jensen and Joel > Stanley says they work for them. Thanks! fttmr010 seem to work OK! I did the usual test on UC-7112-LX [1] after merging linux-nomadik/fttmr0

Re: [PATCH 0/8] clocksource: Generalize Faraday timer

2017-05-18 Thread Jonas Jensen
On 17 May 2017 at 16:05, Linus Walleij wrote: > The patches can be applied as soon as Jonas Jensen and Joel > Stanley says they work for them. Thanks! fttmr010 seem to work OK! I did the usual test on UC-7112-LX [1] after merging linux-nomadik/fttmr010 into next-20170518. [1]

Re: [PATCH v2] net: moxa: fix TX overrun memory leak

2017-03-28 Thread Jonas Jensen
On 28 March 2017 at 05:50, David Miller wrote: > Doing the wakeup unconditionally is very wasteful, you just need to do it > when enough space has been made available. Thanks, please see v3. Jonas

Re: [PATCH v2] net: moxa: fix TX overrun memory leak

2017-03-28 Thread Jonas Jensen
On 28 March 2017 at 05:50, David Miller wrote: > Doing the wakeup unconditionally is very wasteful, you just need to do it > when enough space has been made available. Thanks, please see v3. Jonas

[PATCH v3] net: moxa: fix TX overrun memory leak

2017-03-28 Thread Jonas Jensen
Signed-off-by: Jonas Jensen <jonas.jen...@gmail.com> --- Notes: ChangeLog v2->v3: - add wakeup threshold ChangeLog v1->v2: - stop queue instead of dropping frames Applies to next-20170310 drivers/net/ethernet/moxa/moxart_ether.c | 20 ++-- drivers/

[PATCH v3] net: moxa: fix TX overrun memory leak

2017-03-28 Thread Jonas Jensen
Signed-off-by: Jonas Jensen --- Notes: ChangeLog v2->v3: - add wakeup threshold ChangeLog v1->v2: - stop queue instead of dropping frames Applies to next-20170310 drivers/net/ethernet/moxa/moxart_ether.c | 20 ++-- drivers/net/ethernet/moxa/moxart_e

[PATCH v2] net: moxa: fix TX overrun memory leak

2017-03-27 Thread Jonas Jensen
it on completion. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=99451 Signed-off-by: Jonas Jensen <jonas.jen...@gmail.com> --- Notes: ChangeLog v1->v2: - stop queue instead of dropping frames The following trick was used to trigger the leak. On the ho

[PATCH v2] net: moxa: fix TX overrun memory leak

2017-03-27 Thread Jonas Jensen
it on completion. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=99451 Signed-off-by: Jonas Jensen --- Notes: ChangeLog v1->v2: - stop queue instead of dropping frames The following trick was used to trigger the leak. On the host (where this driver runs):

[PATCH] net: moxa: fix TX overrun memory leak

2015-06-05 Thread Jonas Jensen
tx_head and place tx_tail within spinlock, avoiding read-write race that could happen when interrupts hit at the wrong moment. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=99451 Signed-off-by: Jonas Jensen --- Notes: Applies to next-20150604 drivers/net/ethernet/moxa/moxart_ether.c | 14

[PATCH] net: moxa: fix TX overrun memory leak

2015-06-05 Thread Jonas Jensen
tx_head and place tx_tail within spinlock, avoiding read-write race that could happen when interrupts hit at the wrong moment. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=99451 Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20150604 drivers/net/ethernet

Re: [PATCH v5 1/2] net: moxa: clear TX descriptor length bits

2014-08-25 Thread Jonas Jensen
Thanks for giving feedback. On 20 August 2014 19:10, Eric Dumazet wrote: > Wouldnt it be faster to not use readl() at all here ? On 22 August 2014 06:39, David Miller wrote: > Like others I wonder why the existing descriptor value is being read > at all. It makes sense and I have verified,

Re: [PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-25 Thread Jonas Jensen
Thanks for giving feedback. On 21 August 2014 23:43, Michał Mirosław wrote: > This has implicit: if (!skb) BUG(); There should probably be a return > or continue inside the if (!skb). Fixed, see v6 update (broken out to separate patch) which now includes increment to RX head counter >

[PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread Jonas Jensen
cit napi_gro_flush() Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140825 drivers/net/ethernet/moxa/moxart_ether.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet/moxa/moxart_ethe

[PATCH v6 3/4] net: moxa: synchronize DMA memory

2014-08-25 Thread Jonas Jensen
DMA memory should be synchronized before data is passed to/from controller. Add dma_sync_single_for_cpu(.., DMA_FROM_DEVICE) to RX path and dma_sync_single_for_device(.., DMA_TO_DEVICE) to TX path. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140825 drivers/net/ethernet/moxa

[PATCH v6 1/4] net: moxa: clear DESC1 on ndo_start_xmit()

2014-08-25 Thread Jonas Jensen
TX buffer length is not cleared on ndo_start_xmit(). Failing to do so can bug/hang the controller and cause TX interrupts to stop altogether. Remove the readl() and compute a new value for DESC1. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69031 Signed-off-by: Jonas Jensen --- Notes

[PATCH v6 2/4] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-25 Thread Jonas Jensen
memcpy(). Remove SKB_DATA_ALIGN() from RX buffer size while we're at it. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen --- Notes: Changes since v5: 1. broke out DMA synchronization to separate patch Applies to next-20140825

[PATCH v6 2/4] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-25 Thread Jonas Jensen
memcpy(). Remove SKB_DATA_ALIGN() from RX buffer size while we're at it. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes since v5: 1. broke out DMA synchronization to separate patch Applies

[PATCH v6 1/4] net: moxa: clear DESC1 on ndo_start_xmit()

2014-08-25 Thread Jonas Jensen
TX buffer length is not cleared on ndo_start_xmit(). Failing to do so can bug/hang the controller and cause TX interrupts to stop altogether. Remove the readl() and compute a new value for DESC1. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69031 Signed-off-by: Jonas Jensen jonas.jen

Re: [PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-25 Thread Jonas Jensen
Thanks for giving feedback. On 21 August 2014 23:43, Michał Mirosław mir...@gmail.com wrote: This has implicit: if (!skb) BUG(); There should probably be a return or continue inside the if (!skb). Fixed, see v6 update (broken out to separate patch) which now includes increment to RX head

[PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread Jonas Jensen
napi_gro_flush() Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140825 drivers/net/ethernet/moxa/moxart_ether.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet

[PATCH v6 3/4] net: moxa: synchronize DMA memory

2014-08-25 Thread Jonas Jensen
DMA memory should be synchronized before data is passed to/from controller. Add dma_sync_single_for_cpu(.., DMA_FROM_DEVICE) to RX path and dma_sync_single_for_device(.., DMA_TO_DEVICE) to TX path. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140825

Re: [PATCH v5 1/2] net: moxa: clear TX descriptor length bits

2014-08-25 Thread Jonas Jensen
Thanks for giving feedback. On 20 August 2014 19:10, Eric Dumazet eric.duma...@gmail.com wrote: Wouldnt it be faster to not use readl() at all here ? On 22 August 2014 06:39, David Miller da...@davemloft.net wrote: Like others I wonder why the existing descriptor value is being read at all.

Re: [PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-20 Thread Jonas Jensen
On 19 August 2014 20:31, Eric Dumazet wrote: > Instead of : > > priv->rx_buf_size = RX_BUF_SIZE + > SKB_DATA_ALIGN(sizeof(struct skb_shared_info)); > > I think rx_buf_size can now be RX_BUF_SIZE You're right, that's now a remnant, see update in v5. > Another point is that

[PATCH v5 1/2] net: moxa: clear TX descriptor length bits

2014-08-20 Thread Jonas Jensen
Signed-off-by: Jonas Jensen --- Notes: No changes since v4. Applies to next-20140820 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet/moxa/moxart_ether.c index

[PATCH v5 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-20 Thread Jonas Jensen
memcpy(), and synchronize DMA memory before passing skb to napi_gro_receive(). Remove SKB_DATA_ALIGN() from RX buffer size while we're at it. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen --- Notes: Changes since v4: 1. remove SKB_DATA_ALIGN

Re: fs: panic in mnt_set_mountpoint

2014-08-20 Thread Jonas Jensen
> diff --git a/fs/namespace.c b/fs/namespace.c > index 4246696dc678..a6815027f225 100644 > --- a/fs/namespace.c > +++ b/fs/namespace.c > @@ -736,6 +736,7 @@ static struct mountpoint *new_mountpoint(struct dentry > *dentry) > return ERR_PTR(ret); > } > > +

Re: fs: panic in mnt_set_mountpoint

2014-08-20 Thread Jonas Jensen
diff --git a/fs/namespace.c b/fs/namespace.c index 4246696dc678..a6815027f225 100644 --- a/fs/namespace.c +++ b/fs/namespace.c @@ -736,6 +736,7 @@ static struct mountpoint *new_mountpoint(struct dentry *dentry) return ERR_PTR(ret); } +

[PATCH v5 1/2] net: moxa: clear TX descriptor length bits

2014-08-20 Thread Jonas Jensen
Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: No changes since v4. Applies to next-20140820 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet/moxa

[PATCH v5 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-20 Thread Jonas Jensen
memcpy(), and synchronize DMA memory before passing skb to napi_gro_receive(). Remove SKB_DATA_ALIGN() from RX buffer size while we're at it. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes since v4: 1

Re: [PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-20 Thread Jonas Jensen
On 19 August 2014 20:31, Eric Dumazet eric.duma...@gmail.com wrote: Instead of : priv-rx_buf_size = RX_BUF_SIZE + SKB_DATA_ALIGN(sizeof(struct skb_shared_info)); I think rx_buf_size can now be RX_BUF_SIZE You're right, that's now a remnant, see update in v5. Another point

[PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-19 Thread Jonas Jensen
memcpy(). Also, synchronize DMA memory before passing skb to napi_gro_receive(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen --- Notes: The original motivation was to avoid memcpy(), since the memory is already allocated, why make a copy

[PATCH v4 1/2] net: moxa: clear TX descriptor length bits

2014-08-19 Thread Jonas Jensen
Signed-off-by: Jonas Jensen --- Notes: Changes since v3: 1. commit message reworded Applies to next-20140818 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net

[PATCH v4 2/2] net: moxa: replace build_skb() with netdev_alloc_skb_ip_align() / memcpy()

2014-08-19 Thread Jonas Jensen
memcpy(). Also, synchronize DMA memory before passing skb to napi_gro_receive(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: The original motivation was to avoid memcpy(), since the memory is already allocated

[PATCH v4 1/2] net: moxa: clear TX descriptor length bits

2014-08-19 Thread Jonas Jensen
Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes since v3: 1. commit message reworded Applies to next-20140818 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa

fs: panic in mnt_set_mountpoint

2014-08-18 Thread Jonas Jensen
Hi, I've run into a kernel panic [1] in next-20140818 you might find interesting. It surprised me because there was never an error in next-20140815, I did a search for related panics but it came up empty. The board boots fine after applying the following: diff --git a/fs/namespace.c

fs: panic in mnt_set_mountpoint

2014-08-18 Thread Jonas Jensen
Hi, I've run into a kernel panic [1] in next-20140818 you might find interesting. It surprised me because there was never an error in next-20140815, I did a search for related panics but it came up empty. The board boots fine after applying the following: diff --git a/fs/namespace.c

Re: [RFC PATCH 0/5] watchdog: Add reboot API

2014-05-06 Thread Jonas Jensen
Thanks, Applied in series: 1, 3, and 4 Patches work on moxa UC-7112-LX hardware. Tested-by: Jonas Jensen -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org

Re: [RFC PATCH 0/5] watchdog: Add reboot API

2014-05-06 Thread Jonas Jensen
Thanks, Applied in series: 1, 3, and 4 Patches work on moxa UC-7112-LX hardware. Tested-by: Jonas Jensen jonas.jen...@gmail.com -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to majord...@vger.kernel.org More majordomo info at http

[PATCH] ARM: moxart: add select CLKSRC_OF to ARCH_MOXART

2014-04-11 Thread Jonas Jensen
CLKSRC_OF was recently removed from options selected by ARCH_MULTIPLATFORM, breaking boot on MOXA ART SoCs. Add it to options selected by ARCH_MOXART. Signed-off-by: Jonas Jensen --- Notes: see "Merge tag 'cleanup-3.15' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/ar

[PATCH] ARM: moxart: add select CLKSRC_OF to ARCH_MOXART

2014-04-11 Thread Jonas Jensen
CLKSRC_OF was recently removed from options selected by ARCH_MULTIPLATFORM, breaking boot on MOXA ART SoCs. Add it to options selected by ARCH_MOXART. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: see Merge tag 'cleanup-3.15' of git://git.kernel.org/pub/scm/linux/kernel/git

Re: [PATCH] ARM: reinsert ARCH_MULTI_V4 Kconfig option

2014-04-10 Thread Jonas Jensen
On 9 April 2014 18:01, Russell King - ARM Linux wrote: > It would be useful to see the register state from the undefined > instruction exception. That needs this patch, CONFIG_DEBUG_USER in the > kernel config enabled, and user_debug=1 passed on the kernel command > line. I have done two tests,

Re: [PATCH] ARM: reinsert ARCH_MULTI_V4 Kconfig option

2014-04-10 Thread Jonas Jensen
On 9 April 2014 18:01, Russell King - ARM Linux li...@arm.linux.org.uk wrote: It would be useful to see the register state from the undefined instruction exception. That needs this patch, CONFIG_DEBUG_USER in the kernel config enabled, and user_debug=1 passed on the kernel command line. I

Re: [PATCH] ARM: reinsert ARCH_MULTI_V4 Kconfig option

2014-04-09 Thread Jonas Jensen
On 13 December 2013 12:39, Russell King - ARM Linux wrote: > I see what's causing this: the kuser helpers are using "bx lr" to return > which will be undefined on non-Thumb CPUs. We generally cope fine with > non-Thumb CPUs, conditionalising where necessary on HWCAP_THUMB or the > T bit in the

[PATCH v8] mmc: moxart: Add MOXA ART SD/MMC driver

2014-04-09 Thread Jonas Jensen
Add SD/MMC driver for MOXA ART SoCs. The "MOXA ART MMC controller" is likely a faraday "ftsdc010", a controller with support in U-Boot: http://git.denx.de/?p=u-boot.git;a=blob;f=drivers/mmc/ftsdc010_mci.c Signed-off-by: Jonas Jensen --- Notes: This has been cleaned up

[PATCH v8] mmc: moxart: Add MOXA ART SD/MMC driver

2014-04-09 Thread Jonas Jensen
Add SD/MMC driver for MOXA ART SoCs. The MOXA ART MMC controller is likely a faraday ftsdc010, a controller with support in U-Boot: http://git.denx.de/?p=u-boot.git;a=blob;f=drivers/mmc/ftsdc010_mci.c Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: This has been cleaned up

Re: [PATCH] ARM: reinsert ARCH_MULTI_V4 Kconfig option

2014-04-09 Thread Jonas Jensen
On 13 December 2013 12:39, Russell King - ARM Linux li...@arm.linux.org.uk wrote: I see what's causing this: the kuser helpers are using bx lr to return which will be undefined on non-Thumb CPUs. We generally cope fine with non-Thumb CPUs, conditionalising where necessary on HWCAP_THUMB or the

[PATCH v11] clk: add MOXA ART SoCs clock driver

2014-01-28 Thread Jonas Jensen
MOXA ART SoCs allow to determine PLL output and APB frequencies by reading registers holding multiplier and divisor information. Add a clock driver for this SoC. Signed-off-by: Jonas Jensen --- Notes: Thanks for the replies, Changes since v10: 1. add clock-specifier to DT

[PATCH v11] clk: add MOXA ART SoCs clock driver

2014-01-28 Thread Jonas Jensen
MOXA ART SoCs allow to determine PLL output and APB frequencies by reading registers holding multiplier and divisor information. Add a clock driver for this SoC. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Thanks for the replies, Changes since v10: 1. add

[PATCH] ARM: moxart: DT fixups

2014-01-21 Thread Jonas Jensen
Change DT files to remain coherent with changes in accompanying drivers. 1. replace "sdhci" with "mmc" 2. add bus-width property to mmc node 3. drop device_type property 4. replace "mac@" with "ethernet@" 5. replace CONFIG_MMC_SDHCI_MOXART with CONFIG

[PATCH v3 3/7] net: moxa: connect to PHY

2014-01-21 Thread Jonas Jensen
The kernel now has a MDIO bus driver and a phy_driver (RTL8201CP), connect to this PHY using OF. Signed-off-by: Jonas Jensen --- Notes: Thanks for reviewing, This time I'll avoid sending out the entire set, attaching it here directly to my reply. Because the DT example

[PATCH v10] clk: add MOXA ART SoCs clock driver

2014-01-21 Thread Jonas Jensen
MOXA ART SoCs allow to determine PLL output and APB frequencies by reading registers holding multiplier and divisor information. Add a clock driver for this SoC. Signed-off-by: Jonas Jensen --- Notes: Thanks for the reply Sudeep, changes are in v10. Changes since v9: 1

[PATCH v7] mmc: moxart: Add MOXA ART SD/MMC driver

2014-01-21 Thread Jonas Jensen
Add SD/MMC driver for MOXA ART SoCs. Signed-off-by: Jonas Jensen --- Notes: v6 was supposed to fix a panic from dmaengine_tx_status() but it still happened. This is the sort of panic that lasts between reboots but not between kernel reflash. dmaengine_tx_status() is used

[PATCH v7] mmc: moxart: Add MOXA ART SD/MMC driver

2014-01-21 Thread Jonas Jensen
Add SD/MMC driver for MOXA ART SoCs. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: v6 was supposed to fix a panic from dmaengine_tx_status() but it still happened. This is the sort of panic that lasts between reboots but not between kernel reflash

[PATCH v10] clk: add MOXA ART SoCs clock driver

2014-01-21 Thread Jonas Jensen
MOXA ART SoCs allow to determine PLL output and APB frequencies by reading registers holding multiplier and divisor information. Add a clock driver for this SoC. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Thanks for the reply Sudeep, changes are in v10. Changes

[PATCH v3 3/7] net: moxa: connect to PHY

2014-01-21 Thread Jonas Jensen
The kernel now has a MDIO bus driver and a phy_driver (RTL8201CP), connect to this PHY using OF. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Thanks for reviewing, This time I'll avoid sending out the entire set, attaching it here directly to my reply

[PATCH] ARM: moxart: DT fixups

2014-01-21 Thread Jonas Jensen
Change DT files to remain coherent with changes in accompanying drivers. 1. replace sdhci with mmc 2. add bus-width property to mmc node 3. drop device_type property 4. replace mac@ with ethernet@ 5. replace CONFIG_MMC_SDHCI_MOXART with CONFIG_MMC_MOXART Signed-off-by: Jonas Jensen jonas.jen

[PATCH v3 2/7] net: moxa: fix build_skb() memory corruption

2014-01-20 Thread Jonas Jensen
DMA buffer memory must be synchronized and copied before passing skb to napi_gro_receive(). The use of build_skb() can lead to memory corruption, replace it with netdev_alloc_skb_ip_align() and memcpy(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen

[PATCH v3 6/7] net: moxa: generate random address

2014-01-20 Thread Jonas Jensen
The address register is zero:ed on boot, fill it with a randomly generated address on probe. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/ethernet/moxa

[PATCH v3 3/7] net: moxa: connect to PHY

2014-01-20 Thread Jonas Jensen
The kernel now has a MDIO bus driver and a phy_driver (RTL8201CP), connect to this PHY using OF. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140120 .../devicetree/bindings/net/moxa,moxart-mac.txt| 47 ++- drivers/net/ethernet/moxa/moxart_ether.c | 92

[PATCH v3 7/7] net: moxa: use eth_mac_addr()

2014-01-20 Thread Jonas Jensen
Replace boilerplate in moxart_set_mac_address() with eth_mac_addr(). Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c

[PATCH v3 5/7] net: moxa: add IFF_LIVE_ADDR_CHANGE flag

2014-01-20 Thread Jonas Jensen
.ndo_set_mac_address hook callback already supports IFF_LIVE_ADDR_CHANGE so add it to our flags. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net

[PATCH v3 1/7] net: moxa: clear TX descriptor length bits between sends

2014-01-20 Thread Jonas Jensen
-by: Jonas Jensen --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet/moxa/moxart_ether.c index 5020fd4..aa45607 100644 --- a/drivers/net

[PATCH v3 4/7] net: moxa: add ethtool support

2014-01-20 Thread Jonas Jensen
Add and assign ethtool_ops callback functions. Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 121 +++ 1 file changed, 121 insertions(+) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b

[PATCH v3 4/7] net: moxa: add ethtool support

2014-01-20 Thread Jonas Jensen
Add and assign ethtool_ops callback functions. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 121 +++ 1 file changed, 121 insertions(+) diff --git a/drivers/net/ethernet/moxa

[PATCH v3 1/7] net: moxa: clear TX descriptor length bits between sends

2014-01-20 Thread Jonas Jensen
-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/moxa/moxart_ether.c b/drivers/net/ethernet/moxa/moxart_ether.c index 5020fd4..aa45607

[PATCH v3 5/7] net: moxa: add IFF_LIVE_ADDR_CHANGE flag

2014-01-20 Thread Jonas Jensen
.ndo_set_mac_address hook callback already supports IFF_LIVE_ADDR_CHANGE so add it to our flags. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v3 7/7] net: moxa: use eth_mac_addr()

2014-01-20 Thread Jonas Jensen
Replace boilerplate in moxart_set_mac_address() with eth_mac_addr(). Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/net

[PATCH v3 3/7] net: moxa: connect to PHY

2014-01-20 Thread Jonas Jensen
The kernel now has a MDIO bus driver and a phy_driver (RTL8201CP), connect to this PHY using OF. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 .../devicetree/bindings/net/moxa,moxart-mac.txt| 47 ++- drivers/net/ethernet/moxa

[PATCH v3 6/7] net: moxa: generate random address

2014-01-20 Thread Jonas Jensen
The address register is zero:ed on boot, fill it with a randomly generated address on probe. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140120 drivers/net/ethernet/moxa/moxart_ether.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/net

[PATCH v3 2/7] net: moxa: fix build_skb() memory corruption

2014-01-20 Thread Jonas Jensen
DMA buffer memory must be synchronized and copied before passing skb to napi_gro_receive(). The use of build_skb() can lead to memory corruption, replace it with netdev_alloc_skb_ip_align() and memcpy(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=69041 Signed-off-by: Jonas Jensen

[PATCH v9] clk: add MOXA ART SoCs clock driver

2014-01-17 Thread Jonas Jensen
This patch adds MOXA ART SoCs clock driver support. Signed-off-by: Jonas Jensen --- Notes: Changes since v8: 1. rebase drivers/clk/Makefile to next-20140117 DT bindings document: 2. use two separate sections describing PLL/APB 3. update example

[PATCH v6] mmc: sdhci-moxart: Add MOXA ART SDHCI driver

2014-01-17 Thread Jonas Jensen
Add SDHCI driver for MOXA ART SoCs. Signed-off-by: Jonas Jensen --- Notes: Changes in v6 fixes a kernel panic in moxart_dma_complete(). Panic only happens with CONFIG_SLAB or CONFIG_SLOB, the same code works for CONFIG_SLUB, and happens because a cookie belonging

[PATCH v16] dmaengine: Add MOXA ART DMA engine driver

2014-01-17 Thread Jonas Jensen
driver or client application. Signed-off-by: Jonas Jensen --- Notes: Changes since v15: 1. rebase drivers/dma/Kconfig to next-20140117 Applies to next-20140117 .../devicetree/bindings/dma/moxa,moxart-dma.txt| 45 ++ drivers/dma/Kconfig| 8

[PATCH v16] dmaengine: Add MOXA ART DMA engine driver

2014-01-17 Thread Jonas Jensen
driver or client application. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes since v15: 1. rebase drivers/dma/Kconfig to next-20140117 Applies to next-20140117 .../devicetree/bindings/dma/moxa,moxart-dma.txt| 45 ++ drivers/dma/Kconfig

[PATCH v6] mmc: sdhci-moxart: Add MOXA ART SDHCI driver

2014-01-17 Thread Jonas Jensen
Add SDHCI driver for MOXA ART SoCs. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes in v6 fixes a kernel panic in moxart_dma_complete(). Panic only happens with CONFIG_SLAB or CONFIG_SLOB, the same code works for CONFIG_SLUB, and happens because a cookie

[PATCH v9] clk: add MOXA ART SoCs clock driver

2014-01-17 Thread Jonas Jensen
This patch adds MOXA ART SoCs clock driver support. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Changes since v8: 1. rebase drivers/clk/Makefile to next-20140117 DT bindings document: 2. use two separate sections describing PLL/APB 3. update

[PATCH] ARM: moxart: move fixed rate clock child node to board level dts

2014-01-16 Thread Jonas Jensen
When a skeleton "clocks { .. }" remain in .dtsi, the child node can be moved to .dts, "ref12" is then found by of_clk_get(). Signed-off-by: Jonas Jensen --- Notes: Applies to next-20140116 arch/arm/boot/dts/moxart-uc7112lx.dts | 8 arch/arm/boot/dts/mox

[PATCH] ARM: moxart: move fixed rate clock child node to board level dts

2014-01-16 Thread Jonas Jensen
When a skeleton clocks { .. } remain in .dtsi, the child node can be moved to .dts, ref12 is then found by of_clk_get(). Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Notes: Applies to next-20140116 arch/arm/boot/dts/moxart-uc7112lx.dts | 8 arch/arm/boot/dts/moxart.dtsi

Re: build_skb() and data corruption

2014-01-14 Thread Jonas Jensen
Thanks for the replies, you led me to a new solution, I now think build_skb() is not the right choice, my motivation for using it in the first place, that I thought it meant getting away with not copying memory. build_skb() is replaced by netdev_alloc_skb_ip_align() and memcpy() (derived from

Re: build_skb() and data corruption

2014-01-14 Thread Jonas Jensen
Thanks for the replies, you led me to a new solution, I now think build_skb() is not the right choice, my motivation for using it in the first place, that I thought it meant getting away with not copying memory. build_skb() is replaced by netdev_alloc_skb_ip_align() and memcpy() (derived from

build_skb() and data corruption

2014-01-13 Thread Jonas Jensen
Please help, I think I see memory corruption with a driver recently added to linux-next. The following error occur downloading a large file with wget (or ncftp): "read error: Bad address" wget exits and leaves the file unfinished. The error goes away when build_skb() is patched out, in this

build_skb() and data corruption

2014-01-13 Thread Jonas Jensen
Please help, I think I see memory corruption with a driver recently added to linux-next. The following error occur downloading a large file with wget (or ncftp): read error: Bad address wget exits and leaves the file unfinished. The error goes away when build_skb() is patched out, in this case

Re: [PATCH v6 2/2] ARM: mach-moxart: add MOXA ART SoC device tree files

2013-12-19 Thread Jonas Jensen
On 19 December 2013 00:41, Peter Crosthwaite wrote: >> + clocks { >> + #address-cells = <1>; >> + #size-cells = <0>; >> + >> + ref12: ref12M { >> + compatible = "fixed-clock"; > > Is the correct split to perhaps have the

[PATCH v7 2/2] ARM: mach-moxart: add MOXA ART SoC device tree files

2013-12-19 Thread Jonas Jensen
Add a generic (dtsi) include file for MOXA ART SoCs. Also add a file for UC-7112-LX. Signed-off-by: Jonas Jensen --- Documentation/devicetree/bindings/arm/moxart.txt | 12 ++ arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/moxart-uc7112lx.dts| 117

[PATCH v7 1/2] ARM: mach-moxart: add MOXA ART SoC platform files

2013-12-19 Thread Jonas Jensen
The MOXA ART SoC is based on Faraday's FA526. This is a ARMv4 32-bit 192 MHz CPU with MMU and 16KB/8KB D/I-cache. Add platform support for this SoC. Also add UC-7112-LX as a machine. Signed-off-by: Jonas Jensen --- arch/arm/Kconfig | 2 + arch/arm/Makefile

[PATCH v7 0/2] ARM: mach-moxart: add MOXA ART SoC support

2013-12-19 Thread Jonas Jensen
lk_get() works again. Changes since v6: 1. move fixed rate clock "ref12" from .dtsi to .dts 2. sort new entry alphabetically in arch/arm/Kconfig 3. rebase to next-20131219: arch/arm/Makefile arch/arm/Kconfig Applies to next-20131219 Jonas Jensen (2): ARM: mach-moxart: add MOXA ART So

[PATCH v7 1/2] ARM: mach-moxart: add MOXA ART SoC platform files

2013-12-19 Thread Jonas Jensen
The MOXA ART SoC is based on Faraday's FA526. This is a ARMv4 32-bit 192 MHz CPU with MMU and 16KB/8KB D/I-cache. Add platform support for this SoC. Also add UC-7112-LX as a machine. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- arch/arm/Kconfig | 2 + arch/arm

[PATCH v7 0/2] ARM: mach-moxart: add MOXA ART SoC support

2013-12-19 Thread Jonas Jensen
v6: 1. move fixed rate clock ref12 from .dtsi to .dts 2. sort new entry alphabetically in arch/arm/Kconfig 3. rebase to next-20131219: arch/arm/Makefile arch/arm/Kconfig Applies to next-20131219 Jonas Jensen (2): ARM: mach-moxart: add MOXA ART SoC platform files ARM: mach-moxart: add MOXA ART

[PATCH v7 2/2] ARM: mach-moxart: add MOXA ART SoC device tree files

2013-12-19 Thread Jonas Jensen
Add a generic (dtsi) include file for MOXA ART SoCs. Also add a file for UC-7112-LX. Signed-off-by: Jonas Jensen jonas.jen...@gmail.com --- Documentation/devicetree/bindings/arm/moxart.txt | 12 ++ arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/moxart-uc7112lx.dts

Re: [PATCH v6 2/2] ARM: mach-moxart: add MOXA ART SoC device tree files

2013-12-19 Thread Jonas Jensen
On 19 December 2013 00:41, Peter Crosthwaite peter.crosthwa...@xilinx.com wrote: + clocks { + #address-cells = 1; + #size-cells = 0; + + ref12: ref12M { + compatible = fixed-clock; Is the correct split to perhaps have

[PATCH] watchdog: mach-moxart: add restart handler

2013-12-18 Thread Jonas Jensen
mach-moxart lacks a separate register for reset; as a workaround, add a function that can be hooked to arm_pm_restart. Signed-off-by: Jonas Jensen --- Notes: During review of this driver, the restart handler for moxart was removed, and moved to platform code under arch/arm/mach-moxart

Re: [PATCH v5 2/2] ARM: mach-moxart: add MOXA ART SoC device tree files

2013-12-18 Thread Jonas Jensen
Thanks for the replies, changes should be in v6. On 18 December 2013 00:29, Peter Crosthwaite wrote: >> + clocks { >> + #address-cells = <1>; >> + #size-cells = <0>; >> + >> + ref12: ref12M { >> + compatible = "fixed-clock";

  1   2   3   4   5   >