Re: [linux-sunxi] A23 Labeled as A33 !!

2017-03-29 Thread Bernhard Nortmann
Am 29.03.2017 um 13:19 schrieb Eyad Majali: Hi, I have a Q8 Tablet with the Soc clearly labeled A33 Quad core , when I compiled u-boot for A33 it didnt work and showed error initializing dram, but when compiled for A23 it worked correctly , and gave an ID of 0x1661,of course kernel shows the soc

Re: [linux-sunxi] Problems to Allwinner H3's eFUSE/SID

2016-12-21 Thread Bernhard Nortmann
Side note: Am 19.12.2016 um 16:22 schrieb Icenowy Zheng: [...] According to some facts: - The register based access to SID is weird: it needs ~5 register operations per word of SID. [...] My experiments seem to indicate that Allwinner's implementation might be overly complicated. I have

Re: [linux-sunxi] Problems to Allwinner H3's eFUSE/SID

2016-12-20 Thread Bernhard Nortmann
Hi all! This is rather interesting stuff. Actually it's possible to find partial documentation for this method (of reading SID/efuse values) even for older SoCs. There's an early version of the A20 User Manual (Revision 1.0 - Feb. 18, 2013) available on the net, where chapter 1.18 describes the

[linux-sunxi] Re: In the same situation "sunxi-fel -l" and "sunxi-fel -list" give a different result.

2016-12-17 Thread Bernhard Nortmann
Hi John! Has this been solved for you and/or were you able to test the reworked binaries? Am 13.12.2016 um 13:44 schrieb Bernhard Nortmann: Hello John, I intend to fix this "inconsistent" behaviour by explicitly reporting invalid options (that sunxi-fel did not recognize).

[linux-sunxi] Re: In the same situation "sunxi-fel -l" and "sunxi-fel -list" give a different result.

2016-12-13 Thread Bernhard Nortmann
P.S.: For testing purposes, you can find updated binaries under https://ci.appveyor.com/project/n1tehawk/sunxi-tools/build/v1.4%20%2346/artifacts -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving

[linux-sunxi] Re: In the same situation "sunxi-fel -l" and "sunxi-fel -list" give a different result.

2016-12-13 Thread Bernhard Nortmann
Hello John, I intend to fix this "inconsistent" behaviour by explicitly reporting invalid options (that sunxi-fel did not recognize). See https://github.com/linux-sunxi/sunxi-tools/pull/87/commits/1d2182c That should get rid of "ERROR: Allwinner USB FEL device not found!" in situations where

[linux-sunxi] Re: In the same situation "sunxi-fel -l" and "sunxi-fel -list" give a different result.

2016-12-13 Thread Bernhard Nortmann
Hi John! Am 12.12.2016 um 21:08 schrieb John W. Kitz: Alejandro, Bernhard, When using the prebuilt Win32 binaries of "sunxi-fel", which I downloaded from "https://ci.appveyor.com/project/linuxsunxi/sunxi-tools/build/artifacts; I noticed that in the same situation "sunxi-fel -l" and "sunxi-fel

[linux-sunxi] sunxi-tools v1.4 released

2016-10-26 Thread Bernhard Nortmann
While we're developing continuously at https://github.com/linux-sunxi/sunxi-tools/, it was about time to package up all the changes made since our last "formal" release v1.3 in November 2015. I'd hereby like to announce sunxi-tools v1.4. For release archives, details and a list of all the

Re: [linux-sunxi] usb boot on windows

2016-10-18 Thread Bernhard Nortmann
Am 18.10.2016 um 03:45 schrieb Ronnel Tolentino: Hi Bernhard, It's working now. Thanks. Regards, Ronnel Great. Thanks for your feedback! Regards, B. Nortmann -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group

Re: [linux-sunxi] usb boot on windows

2016-10-17 Thread Bernhard Nortmann
Hello Ronnel! Am 17.10.2016 um 12:24 schrieb Ronnel Tolentino: Hi Bernhard, My PC doesn't recognize the device. ERROR: Allwinner USB FEL device not found! What USB driver do I need? Regards, Ronnel Please be sure to keep the linux-sunxi mailing list in CC. There is no point in making this

Re: [linux-sunxi] Sunxi tools for flashing the eMMC

2016-10-17 Thread Bernhard Nortmann
Am 17.10.2016 um 12:49 schrieb Andre Przywara: [...] I think you can even automate this by some U-Boot environment magic (I think sunxi-fel gained something for this lately). [...] Environment "overrides" using uEnv.txt-style data are still work in progress. The sunxi-tools side of things

Re: [linux-sunxi] MAC address collision on H3

2016-10-17 Thread Bernhard Nortmann
Am 17.10.2016 um 10:21 schrieb LABBE Corentin: Hello An user reported on IRC that he get two OrangePi PC with the same MAC address with uboot 2016.05 and sun8i-emac v4. Giving the following MAC address 02:20:08:00:00:00 He dumped the two SID using devmem2: 2004620 34344314 503A04CE 800

Re: [linux-sunxi] usb boot on windows

2016-10-14 Thread Bernhard Nortmann
Hi Ron! I haven't tried it out, but NextThingCo has added some Windows code in their sunxi-tools fork at https://github.com/NextThingCo/sunxi-tools/branches . The "windows" branch even has a precompiled dist/fel.exe. (If I'm reading things right, it's built against a statically linked mingw32

[linux-sunxi] Re: [PATCH sunxi-tools v3 3/4] nand-image-builder: Rework the help context

2016-06-04 Thread Bernhard Nortmann
tion long_options[] = { {"help", no_argument, 0, 0}, {"ecc", required_argument, 0, 'c'}, - {"page-size", required_argument, 0, 'p'}, - {"oob-size", required_argume

Re: [linux-sunxi] [PATCH sunxi-tools v2 3/3] nand-image-builder: Rework the help context

2016-06-02 Thread Bernhard Nortmann
Am 02.06.2016 um 17:33 schrieb Boris Brezillon: Add explanations on where the options to pass to the tool should be extracted from, and add two examples to illustrate this explanation. Signed-off-by: Boris Brezillon --- Changes since v1: - use shorter option

[linux-sunxi] Re: [PATCH sunxi-tools v2 1/3] nand-image-builder: Fix the copyright header

2016-06-02 Thread Bernhard Nortmann
c | 49 - 1 file changed, 8 insertions(+), 41 deletions(-) Looks good to me now. Acked-by: Bernhard Nortmann <bernhard.nortm...@web.de> -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe fr

Re: [linux-sunxi] [PATCH] [V2] ARM: dts: sun7i: Add dts file for Bananapi M1 Plus board

2016-06-02 Thread Bernhard Nortmann
Am 02.06.2016 um 10:16 schrieb Maxime Ripard: [...] Yes, everything that is shared with the banana-pro (which, judging from Bernhard, is pretty much everything but a GPIO) should be merged in the banapro DT. Maxime Don't take my word for granted, as I do not own this hardware or know it

[linux-sunxi] Re: [PATCH sunxi-tools 3/3] nand-image-builder: Add more details in the help context

2016-06-01 Thread Bernhard Nortmann
Am 01.06.2016 um 11:05 schrieb Boris Brezillon: Add explanation on where the options to pass to the tool should be extracted from, and add two examples to illustrate this explanation. Signed-off-by: Boris Brezillon --- nand-image-builder.c | 17

[linux-sunxi] Re: [PATCH sunxi-tools 2/3] nand-image-builder: Add error messages to check_image_info()

2016-06-01 Thread Bernhard Nortmann
e + (eccsteps * (eccbytes))) { When changing that line, please strip the surplus braces around `eccbytes`. + fprintf(stderr, + "ECC bytes do not fit in the NAND page, choose a weaker ECC\n"); return -EINVAL; + } return 0; } Apa

[linux-sunxi] Re: [PATCH sunxi-tools 1/3] nand-image-builder: Fix the copyright header

2016-06-01 Thread Bernhard Nortmann
Am 01.06.2016 um 11:05 schrieb Boris Brezillon: Add NextThing Co. and Free Electrons copyrights and add myself as the author of the randomizer and image builder implementation. Remove the lengthy description explaining how the BCH implementation works, since this is the purpose of this tool is

Re: [linux-sunxi] [PATCH sunxi-tools] Add a tool to generate raw NAND images

2016-05-30 Thread Bernhard Nortmann
Am 30.05.2016 um 17:12 schrieb Boris Brezillon: Generating raw NAND images is particularly useful for boot0 images creation since the mainline driver is not supporting the funky layout used by Allwinner's ROM code to load the boot0 binary from NAND. This tools also allows one to generate raw

Re: [linux-sunxi] Re: [PATCH] ARM: dts: sun7i: Add dts file for Bananapi M1 Plus board

2016-05-30 Thread Bernhard Nortmann
Am 30.05.2016 um 21:43 schrieb Maxime Ripard: Hi, On Mon, May 30, 2016 at 08:30:13PM +0800, luoyi...@gmail.com wrote: From: luoyi Add support for the Bananapi M1 Plus A20 development board from sinovoip.com.cn . This board features 1G RAM, 2 USB A receptacles, 1 micro

Re: [linux-sunxi] Re: [PATCH sunxi-tools] Add a tool to generate raw NAND images

2016-05-30 Thread Bernhard Nortmann
Thanks for your kind words, Siarhei - and hi Boris! Am 30.05.2016 um 18:13 schrieb Siarhei Siamashka: Hi Boris, Regarding the sunxi-tools repository maintenance, personally I'm trying my best to slack off and offload all the bureaucratic duties to Bernhard :-) About submitting patches. Yes,

Re: [linux-sunxi] [sunxi-tools PATCH 0/5] Experimental A64 support

2016-05-12 Thread Bernhard Nortmann
Am 05.05.2016 um 20:49 schrieb Bernhard Nortmann: This patch series is based on original work by ssvb available at https://github.com/ssvb/sunxi-tools/tree/20160123-allwinner-a64-support with slight modifications to rebase it on top of current master. An experimental branch has been set up

[linux-sunxi] [sunxi-tools PATCH 5/5] fel: Add fel spl command support for Allwinner A64

2016-05-05 Thread Bernhard Nortmann
SCTLR check can be relaxed. Tested using a custom built UART0 hello world bootable image. Signed-off-by: Siarhei Siamashka <siarhei.siamas...@gmail.com> Reviewed-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 23 +-- 1 file changed, 21 insertions(+), 2

[linux-sunxi] [sunxi-tools PATCH 4/5] fel: Move the backup storage to the SRAM section A1 on H3

2016-05-05 Thread Bernhard Nortmann
From: Siarhei Siamashka This allows the SRAM section A2 to be exclusively used by the OpenRISC core. There are no substantial differences between H3 and A10/A13/A20. It just has 64 KiB of SRAM starting at the address 0x0 instead of 48 KiB. Signed-off-by: Siarhei

[linux-sunxi] [sunxi-tools PATCH 0/5] Experimental A64 support

2016-05-05 Thread Bernhard Nortmann
This patch series is based on original work by ssvb available at https://github.com/ssvb/sunxi-tools/tree/20160123-allwinner-a64-support with slight modifications to rebase it on top of current master. An experimental branch has been set up for the sunxi-tools repository at

[linux-sunxi] [sunxi-tools PATCH 1/5] fel: Move backup area to higher addresses in SRAM on A10/A13/A20

2016-05-05 Thread Bernhard Nortmann
l tool compatible with 40 KiB SPLs, even though the current U-Boot releases do not use them yet. Signed-off-by: Siarhei Siamashka <siarhei.siamas...@gmail.com> Acked-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 20 1 file changed, 12 insertions(+), 8 deleti

[linux-sunxi] [sunxi-tools PATCH 2/5] fel: Rename the backup buffers which use AR100 (OpenRISC) SRAM

2016-05-05 Thread Bernhard Nortmann
From: Siarhei Siamashka <siarhei.siamas...@gmail.com> That would be a more appropriate name. And A31 is going to implement this in a different way and give the SRAM back to OpenRISC. Signed-off-by: Siarhei Siamashka <siarhei.siamas...@gmail.com> Acked-by: Bernhard Nortmann <

[linux-sunxi] [sunxi-tools PATCH 3/5] fel: Move the backup storage to the SRAM B on A31

2016-05-05 Thread Bernhard Nortmann
me UCL or LZO decompression can be used to unpack the SPL code to 0x24000-0x2 and have 48 KiB of available space there. Signed-off-by: Siarhei Siamashka <siarhei.siamas...@gmail.com> Reviewed-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 17 +++-- 1 file chan

[linux-sunxi] Re: [PATCH sunxi-tools 0/5] Add continuous integration support (Travis CI), fix Mac OS X build

2016-05-05 Thread Bernhard Nortmann
FYI: After merging https://github.com/linux-sunxi/sunxi-tools/pull/40 and some additional work, we now have Travis CI doing checks on builds and pull requests - for both Linux and Mac OS X. See e.g. https://travis-ci.org/linux-sunxi/sunxi-tools/builds/127986205 Regards, B. Nortmann -- You

[linux-sunxi] [sunxi-tools PATCH 1/3] fel: Move the temporary scratch buffer under the IRQ stack

2016-04-29 Thread Bernhard Nortmann
iamashka <siarhei.siamas...@gmail.com> Tested-by: Bernhard Nortmann <bernhard.nortm...@web.de> Reviewed-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/fel.c b/fel.c index 83a78

[linux-sunxi] [sunxi-tools PATCH 2/3] fel: Add "readl" and "writel" commands

2016-04-29 Thread Bernhard Nortmann
Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> Squashed commit of the following: commit 95f3614357446c4a35ec541bb2c21503c54d3fac Author: Bernhard Nortmann <bernhard.nortm...@web.de> Date: Fri Apr 8 09:10:17 2016 +0200 fel: Add support for multiple sequential

[linux-sunxi] [sunxi-tools PATCH 0/3] fel: Add new readl/writel functionality and a "sid" command

2016-04-29 Thread Bernhard Nortmann
a "sunxi-fel sid" command. For further background information, also see: https://github.com/linux-sunxi/sunxi-tools/issues/38 Regards, B. Nortmann Bernhard Nortmann (2): fel: Add "readl" and "writel" commands fel: add "sid" command to print SID

[linux-sunxi] [PATCH sunxi-tools 1/5] Add Travis CI configuration file

2016-04-15 Thread Bernhard Nortmann
Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- .travis.yml | 26 ++ 1 file changed, 26 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000..d276863 --- /dev/null +++ b/.travis.yml @

[linux-sunxi] [PATCH sunxi-tools 4/5] Have portable_endian.h properly expose all functions

2016-04-15 Thread Bernhard Nortmann
this by using symbols provided "globally" via the Makefile. Also nuke the _NETBSD_SOURCE definition in fel.c Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- Makefile | 9 - fel.c | 6 -- include/portable_endian.h | 0

[linux-sunxi] [PATCH sunxi-tools 3/5] Replace endian_compat.h with portable_endian.h

2016-04-15 Thread Bernhard Nortmann
, let's do away with it completely and replace it by something more sophisticated. The portable_endian.h used is in the public domain, and was taken from https://gist.github.com/panzi/6856583 Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c |

[linux-sunxi] [PATCH sunxi-tools 0/5] Add continuous integration support (Travis CI), fix Mac OS X build

2016-04-15 Thread Bernhard Nortmann
) on other platforms. Regards, B. Nortmann Bernhard Nortmann (5): Add Travis CI configuration file fel: Introduce helper function for reporting libusb errors Replace endian_compat.h with portable_endian.h Have portable_endian.h properly expose all functions nand-part: Avoid Linux-

[linux-sunxi] [PATCH sunxi-tools 5/5] nand-part: Avoid Linux-only ioctl() on other platforms

2016-04-15 Thread Bernhard Nortmann
The nand-part.c code tries to re-read the partition tables by issuing an ioctl(fd, BLKRRPART, NULL). This isn't available on non-Linux platforms, e.g. Mac OS X. Add preprocessor conditionals to prevent this from breaking the build. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web

[linux-sunxi] [PATCH sunxi-tools] fel: Introduce helper function for reporting libusb errors

2016-04-12 Thread Bernhard Nortmann
this, refactor existing code and have more streamlined error reporting - avoiding the message string retrieval where needed. The usb_error() function can also optionally abort execution with a given exit code. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.

[linux-sunxi] [PATCH sunxi-tools] fexc: Improve script_decompile_bin() safeguards

2016-04-10 Thread Bernhard Nortmann
97186.-1073906177". Also reordered lines so that the safeguards run (and exit, if needed) before the normal output of header information. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- script_bin.c | 38 +- 1 file changed, 17 i

[linux-sunxi] Re: [PATCH sunxi-tools 4/7] fel: Move the backup storage to the SRAM section A1 on H3

2016-04-03 Thread Bernhard Nortmann
>This allows the SRAM section A2 to be exclusively used by >the OpenRISC core. > >There are no substantial differences between H3 and A10/A13/A20. >It just has 64 KiB of SRAM starting at the address 0x0 instead >of 48 KiB. > >Signed-off-by: Siarhei Siamashka >---

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-31 Thread Bernhard Nortmann
Am Montag, 25. Januar 2016 05:51:02 UTC+1 schrieb Siarhei Siamashka: The read/write operations done by FEL are not suitable for accessing hardware registers. For example, trying to read a SID value using the "read" or "hexdump" commands results in the following: $ sunxi-fel hexdump 0x01c23800

[linux-sunxi] [PATCH sunxi-tools v3 3/3] fel: Use initializers for aw_usb_request and aw_fel_request

2016-03-23 Thread Bernhard Nortmann
instead of memset() and strcpy() to clear / assign member fields. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 23 --- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/fel.c b/fel.c index 495aa81..62f2fa8 100644 --- a/fel.c

[linux-sunxi] [PATCH sunxi-tools v3 1/3] fel: Minor fixes

2016-03-23 Thread Bernhard Nortmann
formatting adjustments. - Convert "needs_l2en" to boolean type. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 41 - 1 file changed, 20 insertions(+), 21 deletions(-) diff --git a/fel.c b/fel.c index dedde55..0a36607 1006

[linux-sunxi] [PATCH sunxi-tools v3 2/3] fel: Simplify hexdump() single character output, using putchar()

2016-03-23 Thread Bernhard Nortmann
Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/fel.c b/fel.c index 0a36607..495aa81 100644 --- a/fel.c +++ b/fel.c @@ -322,16 +322,14 @@ void hexdump(void *data, uint32_t offset, size_

[linux-sunxi] [PATCH sunxi-tools v3 0/3] fel: Minor fixes

2016-03-23 Thread Bernhard Nortmann
Changes in v2: - Rebased to current master - Added some formatting adjustments - Added a second patch that simplifies hexdump() Changes in v3: - Convert "needs_l2en" to boolean type. - Add another patch that uses initializers for aw_(usb|fel)_request Bernhard Nortmann (3): fel: M

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-23 Thread Bernhard Nortmann
Hello Siarhei! I'm still catching up in my understanding of the concepts and inner workings of the fel utility and its relationship with the BROM code. Thanks to your detailed explanations, the picture has gotten a lot clearer. What's the expected usage (required size in bytes) of the

[linux-sunxi] [PATCH sunxi-tools v2 0/2] fel: Minor fixes

2016-03-21 Thread Bernhard Nortmann
Changes in v2: - Rebased to current master - Added some formatting adjustments - Added a second patch that simplifies hexdump() Bernhard Nortmann (2): fel: Minor fixes fel: Simplify hexdump() single character output, using putchar() fel.c | 43 --- 1

[linux-sunxi] [PATCH sunxi-tools v2 2/2] fel: Simplify hexdump() single character output, using putchar()

2016-03-21 Thread Bernhard Nortmann
Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/fel.c b/fel.c index 616cd05..da006ac 100644 --- a/fel.c +++ b/fel.c @@ -322,16 +322,14 @@ void hexdump(void *data, uint32_t offset, size_

[linux-sunxi] [PATCH sunxi-tools v2 1/2] fel: Minor fixes

2016-03-21 Thread Bernhard Nortmann
formatting adjustments. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 35 +-- 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/fel.c b/fel.c index dedde55..616cd05 100644 --- a/fel.c +++ b/fel.c @@ -80,7 +80,7 @@ static vo

[linux-sunxi] [PATCH] fel: Minor fixes

2016-03-20 Thread Bernhard Nortmann
- Do a clean shutdown / exit(0) after printing usage help, instead of continuing execution. This avoids the "ERROR: Allwinner USB FEL device not found!" when doing a plain ./sunxi-fel without any arguments. - Convert C++ style comments for uniform coding style. Signed-off-by

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-20 Thread Bernhard Nortmann
Hi Siarhei! Am 20.03.2016 um 15:49 schrieb Siarhei Siamashka: This patch is just unsafe if pushed alone, that's why it implicitly depends on the other "fel: Move the temporary scratch buffer under the IRQ stack" patch. I see. My impression was that while "unclean" on its own, it's still

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-20 Thread Bernhard Nortmann
https://github.com/linux-sunxi/sunxi-tools/issues/37), so feel free to commit it. Reviewed-by: Bernhard Nortmann <bernhard.nortm...@web.de> -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and

[linux-sunxi] Re: [PATCH sunxi-tools v5] fel: support selection of specific USB bus and device number

2016-03-20 Thread Bernhard Nortmann
Thanks! Committed to sunxi-tools/master. -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For more options, visit

Re: [linux-sunxi] [PATCH sunxi-tools] fel: Add release USB interface to allow proper operation on Mac OS X.

2016-03-20 Thread Bernhard Nortmann
Thanks! Commited and closed PR accordingly. Regards, B,. Nortmann -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For

[linux-sunxi] Re: [PATCH sunxi-tools v5] fel: support selection of specific USB bus and device number

2016-03-20 Thread Bernhard Nortmann
Am 20.03.2016 um 13:53 schrieb Siarhei Siamashka: Thanks, also adding an extra || busnum < 0 || devnum < 0 check here would make it perfect. If the user tries to provide negative numbers in the command line, then it is reasonable to fail with an error instead of silently

[linux-sunxi] [PATCH sunxi-tools v3] fel: support selection of specific USB bus and device number

2016-03-19 Thread Bernhard Nortmann
uot;handle == NULL" error handler from main() to request_libusb_handle() - Add missing "Signed-off-by:" Bernhard Nortmann (1): fel: support selection of specific USB bus and device number fel.c | 101 +++--- 1 file

[linux-sunxi] [PATCH sunxi-tools v5] fel: support selection of specific USB bus and device number

2016-03-19 Thread Bernhard Nortmann
ssues Changes in v5: - Renamed libusb_open_device() to open_fel_device(), otherwise unsuspecting readers might mistake it for a libusb library routine. - Declare the 'magic' Allwinner FEL VID/PID constants near the top of file. Bernhard Nortmann (1): fel: support selection o

[linux-sunxi] [PATCH sunxi-tools v4] fel: support selection of specific USB bus and device number

2016-03-19 Thread Bernhard Nortmann
uot;handle == NULL" error handler from main() to request_libusb_handle() - Add missing "Signed-off-by:" Changes in v4: - Reworked commit message - Handle possible libusb errors more consistently - Be more strict on parsing "bus:devnum" device specifier - Fixed various style issue

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-19 Thread Bernhard Nortmann
Am 17.03.2016 um 13:55 schrieb Bernhard Nortmann: I can confirm/reproduce this behaviour on my A20 when accessing the SID register. Interesting enough, the bytes that actually do get read (i.e. end up != 0) are "correct", as if the aw_usb_read() somehow truncates everything down

[linux-sunxi] [PATCH sunxi-tools v3] fel: support selection of specific USB bus and device number

2016-03-19 Thread Bernhard Nortmann
See https://github.com/linux-sunxi/sunxi-tools/issues/37 The patch introduces a "--dev" (-d) option to specify the desired FEL device. This is useful if multiple target devices are connected to the same host. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de>

[linux-sunxi] [PATCH sunxi-tools v4] fel: support selection of specific USB bus and device number

2016-03-19 Thread Bernhard Nortmann
FEL device. This is useful if multiple target devices are connected to the same host. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 122 +- 1 file changed, 98 insertions(+), 24 deletions(-) diff --git a/fel.c b/fel

[linux-sunxi] [PATCH sunxi-tools] fel: Add release USB interface to allow proper operation on Mac OS X.

2016-03-19 Thread Bernhard Nortmann
This picks up a long-standing pull request from the github repo that seemingly noone cared to take forward to the mailing list. The one-line change looks sane, and reportedly is needed for proper operation when issuing repeated sunxi-fel commands on Mac OS X. NextThingCo also uses it in their

[linux-sunxi] Re: [PATCH sunxi-tools 5/7] fel: Move the temporary scratch buffer under the IRQ stack

2016-03-19 Thread Bernhard Nortmann
github.com/ssvb/sunxi-tools/commit/a99c75f4d05349622b4ebd4c3054a0b6acb9d5af) first. Tested-by: Bernhard Nortmann <bernhard.nortm...@web.de> -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an

[linux-sunxi] Re: [PATCH sunxi-tools 6/7] fel: Add "readl" and "writel" commands

2016-03-19 Thread Bernhard Nortmann
mp;& argc > 2) { + uint32_t addr = strtoul(argv[2], NULL, 0); + uint32_t val = strtoul(argv[3], NULL, 0); + aw_fel_writel(handle, addr, val); + skip = 3; } else if (strncmp(argv[1], "e

Re: [linux-sunxi] [PATCH sunxi-tools v3] fel: support selection of specific USB bus and device number

2016-03-18 Thread Bernhard Nortmann
Hi Siarhei! Am 16.03.2016 um 17:58 schrieb Siarhei Siamashka: Hello Bernhard, Thanks, this is clearly a useful feature. [...] Should we also give more explicit credit in the commit message to NextThingCo people for their work on the initial implementation of this patch? Yes, I know that the

[linux-sunxi] [PATCH sunxi-tools v5] fel: support selection of specific USB bus and device number

2016-03-18 Thread Bernhard Nortmann
FEL device. This is useful if multiple target devices are connected to the same host. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 129 -- 1 file changed, 103 insertions(+), 26 deletions(-) diff --git a/fel

[linux-sunxi] Fwd: [PATCH sunxi-tools 1/7] fel: Move backup area to higher addresses in SRAM on A10/A13/A20

2016-03-18 Thread Bernhard Nortmann
ot") U-Boot 2015.10 on A20 with this modification, _before_ applying 5/7. Tested-by: Bernhard Nortmann <bernhard.nortm...@web.de> -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receivi

[linux-sunxi] [PATCH sunxi-tools] fel: Add release USB interface to allow proper operation on Mac OS X.

2016-03-18 Thread Bernhard Nortmann
From: Lourens Rozema <lroz...@embed.nl> Tested-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fel.c b/fel.c index 59f0f72..c81077f 100644 --- a/fel.c +++ b/fel.c @@ -1437,6 +1437,7 @@ int main(int argc,

[linux-sunxi] [PATCH sunxi-tools v2] fel: support selection of specific USB bus and device number

2016-03-16 Thread Bernhard Nortmann
Changes in v2: - Renamed "char *dev" to "char *dev_arg", to make it clearer that we're working on the device argument. Use strspn(dev_arg,...) instead of strspn(argv[1],...) Bernhard Nortmann (1): fel: support selection of specific USB bus and device

[linux-sunxi] [PATCH sunxi-tools v2] fel: support selection of specific USB bus and device number

2016-03-16 Thread Bernhard Nortmann
See https://github.com/linux-sunxi/sunxi-tools/issues/37 The patch introduces a "--dev" (-d) option to specify the desired FEL device. This is useful if multiple target devices are connected to the same host. --- fel.c | 81 --- 1

[linux-sunxi] [PATCH sunxi-tools] fel: support selection of specific USB bus and device number

2016-03-16 Thread Bernhard Nortmann
See https://github.com/linux-sunxi/sunxi-tools/issues/37 The patch introduces a "--dev" (-d) option to specify the desired FEL device. This is useful if multiple target devices are connected to the same host. --- fel.c | 81 --- 1

[linux-sunxi] Re: fel-sdboot.sunxi problems on Cubietruck and A20-OLinuXino-MICRO

2016-01-04 Thread Bernhard Nortmann
Am Dienstag, 29. Dezember 2015 22:33:08 UTC+1 schrieb Piotr Król: This image also cannot enter FEL mode. Have you got access to >4.7 GCC on Gentoo ? Can you try it ? I've recently updated my crossdev-toolchain - it doesn't change much. Using sunxi-tools # armv7a-hardfloat-linux-gnueabi-gcc

[linux-sunxi] Re: fel-sdboot.sunxi problems on Cubietruck and A20-OLinuXino-MICRO

2015-12-29 Thread Bernhard Nortmann
For reference: The fel-sdboot.bin I compiled myself was also done with a Gentoo cross-compiler sunxi-tools # armv7a-hardfloat-linux-gnueabi-gcc -v Using built-in specs. COLLECT_GCC=/usr/i686-pc-linux-gnu/armv7a-hardfloat-linux-gnueabi/gcc-bin/4.8.3/armv7a-hardfloat-linux-gnueabi-gcc

[linux-sunxi] Re: fel-sdboot.sunxi problems on Cubietruck and A20-OLinuXino-MICRO

2015-12-29 Thread Bernhard Nortmann
I've just noticed that omitting all options from the compilation alters the binary. With the options explicitly listed in fel-sdboot.c, I get this: sunxi-tools # armv7a-hardfloat-linux-gnueabi-gcc -g -Os -fno-common -ffixed-r8 -msoft-float -fno-builtin -ffreestanding -nostdinc

[linux-sunxi] Re: fel-sdboot.sunxi problems on Cubietruck and A20-OLinuXino-MICRO

2015-12-18 Thread Bernhard Nortmann
Hi Piotr! I've tried this on an A20 Banana Pi (model 1), and entering FEL mode works for me - both with the prebuilt bin/fel-sdboot.sunxi and with a binary freshly compiled from fel-sdboot.c according to instructions. With the SD card prepared and inserted, powering on or resetting the A20

[linux-sunxi] Re: [PATCH 1/2] sunxi-tools: some trivial fixes

2015-12-16 Thread Bernhard Nortmann
ore options, visit https://groups.google.com/d/optout. >From 7c61032b503ab8cded6dc49e5b960d7030229525 Mon Sep 17 00:00:00 2001 From: Bernhard Nortmann <bernhard.nortm...@web.de> Date: Wed, 16 Dec 2015 11:25:46 +0100 Subject: [PATCH sunxi-tools] fel: bugfix - revert autostart change from d9

[linux-sunxi] [PATCH sunxi-tools] fel: fix memory leak, properly shut down USB library

2015-12-16 Thread Bernhard Nortmann
The aw_fel_process_spl_and_uboot() was missing a free() for the file buffer. This patch also adds a proper libusb cleanup/shutdown. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fel.c b/fel.c index fdd6d35..5

[linux-sunxi] Re: [PATCH v5 7/9] sunxi-tools: implement "write-with-progress" and "multiwrite"

2015-12-07 Thread Bernhard Nortmann
linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. >From b6966d19269d33baaa79a7af5548ba79f0505673 Mon Sep 17 00:00:00 2001 From: Bern

[linux-sunxi] Re: [PATCH v5 9/9] sunxi-tools: support updating the caption for "dialog --gauge"

2015-12-07 Thread Bernhard Nortmann
linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. >From 73d7989148f32f5183cbce2c49081f89203a3254 Mon Sep 17 00:00:00 2001 From: Bern

[linux-sunxi] Re: [PATCH v5 6/9] sunxi-tools: Add file_size() and factor out a reusable file_upload()

2015-12-07 Thread Bernhard Nortmann
s, visit https://groups.google.com/d/optout. >From 3bf01420a4dabc1894af84bbaa829325f22d97ad Mon Sep 17 00:00:00 2001 From: Bernhard Nortmann <bernhard.nortm...@web.de> Date: Thu, 26 Nov 2015 15:36:43 +0100 Subject: [PATCH v6 6/9] fel: Add file_size() and factor out a reusable file_uplo

[linux-sunxi] Re: [PATCH v5 0/8] sunxi-tools: support progress display for FEL utility

2015-12-07 Thread Bernhard Nortmann
Hi Siarhei! Am 30.11.2015 um 12:44 schrieb Siarhei Siamashka: Hello, I think that patches 1-5 can be pushed to github, even though I'm not completely happy about certain aspects of them. The patches 6-9 may need some additional fixes. Oh, by the way. The "sunxi-tools:" prefix in the commit

[linux-sunxi] Re: [PATCH v5 8/9] sunxi-tools: support FEL progress gauge via dialog utility

2015-12-07 Thread Bernhard Nortmann
receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. >From a875406070f69c8bf77625fa91c46a166519c4e0 Mon Sep 17 00:00:00 2001 From: Bernhard Nortmann <bernhard.nortm...@web.de> Date: Thu, 26 Nov 2015 16:

[linux-sunxi] Re: [PATCH v3 0/9] sunxi-tools: support progress display for FEL utility

2015-11-27 Thread Bernhard Nortmann
Hi Siarhei! Am 20.11.2015 um 13:57 schrieb Siarhei Siamashka: [...] If I understand you correctly, you'd do away with the "-p" and "-g[g]" switches and instead use dedicated "[multi]progress" and "[multi][x]gauge" commands, behaving like what would now be achieved with one of the progress

[linux-sunxi] [PATCH v5 7/9] sunxi-tools: implement "write-with-progress" and "multiwrite"

2015-11-27 Thread Bernhard Nortmann
The two new commands both imply that a (simple) progress bar display is requested. "multi[write]" allows to upload a group of files with a single command, resulting in their transfer showing a common, 'overall' progress status. Signed-off-by: Bernhard Nortmann <bernhard.no

[linux-sunxi] [PATCH v5 1/9] sunxi-tools: Introduce progress framework

2015-11-27 Thread Bernhard Nortmann
there. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- Makefile | 2 +- fel.c | 10 +- progress.c | 40 progress.h | 34 ++ 4 files changed, 76 insertions(+), 10 deletions(-) create mode

[linux-sunxi] [PATCH v5 6/9] sunxi-tools: Add file_size() and factor out a reusable file_upload()

2015-11-27 Thread Bernhard Nortmann
by "-p". Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 45 + 1 file changed, 29 insertions(+), 16 deletions(-) diff --git a/fel.c b/fel.c index 595b682..c9081b6 100644 --- a/fel.c +++ b/fel.c @@ -32,6 +32,7 @@ #incl

[linux-sunxi] [PATCH v5 2/9] sunxi-tools: refactor aw_fel_write()

2015-11-27 Thread Bernhard Nortmann
fill" or "clear" commands. There is some deliberate code duplication here that makes sense when combined with the next patch, where the aw_usb_write() call will differ. We want aw_fel_write() to enforce no progress update/callback, while aw_write_buffer() will (optionally) suppo

[linux-sunxi] [PATCH v5 4/9] sunxi-tools: implement simple progress bar for larger transfers

2015-11-27 Thread Bernhard Nortmann
Add "--progress" option and a progress bar display for FEL transfers. This picks up on a suggestion from Alexander Kaplan and the discussion at https://groups.google.com/forum/#!topic/linux-sunxi/lz0oQBwjex0 Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> ---

[linux-sunxi] [PATCH v5 0/8] sunxi-tools: support progress display for FEL utility

2015-11-27 Thread Bernhard Nortmann
he more verbose options are mainly intended for scripting.) Changes in v4: - An attempt to support "per SoC" chunk size selection, now OBSOLETE. Bernhard Nortmann (9): sunxi-tools: Introduce progress framework sunxi-tools: refactor aw_fel_write() sunxi-tools: extend usb_bulk_s

[linux-sunxi] [PATCH v5 8/9] sunxi-tools: support FEL progress gauge via dialog utility

2015-11-27 Thread Bernhard Nortmann
ot; outputs extended information to update the dialog prompt. Both are meant for directly piping theoutput: sunxi-fel write-with-gauge <...> | dialog --gauge "FEL upload" 6 70 Signed-off-by: Bernhard Nortmann <bernhar

[linux-sunxi] [PATCH v5 3/9] sunxi-tools: extend usb_bulk_send() for progress updates

2015-11-27 Thread Bernhard Nortmann
ced inactive in most other places, e.g. aw_fel_write_uboot_image(). Also, we specifically want the internal use of aw_fel_write() to never use it. Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 36 ++-- 1 file changed, 22 insertions(+), 1

[linux-sunxi] [PATCH v5 9/9] sunxi-tools: support updating the caption for "dialog --gauge"

2015-11-27 Thread Bernhard Nortmann
otfs (2/2)" \ write-with-gauge 0x4400 ${ROOTFS} \ | dialog --gauge "" 6 70 Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 4 1 file changed, 4 insertions(+) diff --git a/fel.c b/fel.c index 2e948fd..c4bf80f 100644 ---

[linux-sunxi] Re: [PATCH v5 1/9] sunxi-tools: Introduce progress framework

2015-11-27 Thread Bernhard Nortmann
There's a typo in the commit message that went unnoticed, I've fixed it now . s/deal will code/deal with code/ Regards, B. Nortmann -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from

[linux-sunxi] [PATCH 0/2] sunxi-tools: stuff to possibly go into 0.3

2015-11-19 Thread Bernhard Nortmann
Siarhei: Here are the proposed changes that I would like to go into sunxi-tools, possibly before you tag a 0.3 release. It's not urgent (could be postponed to a later point in time), but I think it would be nice to include these into a "release point". Regards, B. Nortmann Bernhard N

[linux-sunxi] [PATCH 2/2] sunxi-tools: make use of proper boolean data types

2015-11-19 Thread Bernhard Nortmann
Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/fel.c b/fel.c index 4561d02..348f01c 100644 --- a/fel.c +++ b/fel.c @@ -23,6 +23,7 @@ #include #include +#include #include #i

[linux-sunxi] [PATCH 1/2] sunxi-tools: some trivial fixes

2015-11-19 Thread Bernhard Nortmann
- get rid of double includes - fix U-Boot source reference - get rid of "uboot_autostart" variable Signed-off-by: Bernhard Nortmann <bernhard.nortm...@web.de> --- fel.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/fel.c b/fel.c index e9f6450

Re: [linux-sunxi] [PATCH 0/2] sunxi-tools: stuff to possibly go into 0.3

2015-11-19 Thread Bernhard Nortmann
Am 19.11.2015 um 16:43 schrieb Peter Korsgaard: Both look good to me, thanks. Acked-by: Peter Korsgaard Thanks! Applied to linux-sunxi/sunxi-tools And in turn that also means: No objections from me against tagging a 0.3 release. Regards, B. Nortmann -- You received

[linux-sunxi] Re: [PATCH v3 0/9] sunxi-tools: support progress display for FEL utility

2015-11-19 Thread Bernhard Nortmann
Hi Siarhei! Am 19.11.2015 um 09:04 schrieb Siarhei Siamashka: [...] My biggest concern is the command line interface. It is basically stateless vs. stateful approach. You are in favour of allowing switches, which modify the state anywhere in the command line and then have regular commands

  1   2   >