If a variable is used as array subscript, it's valid value range is
0 ... ARRAY_SIZE -1.
Signed-off-by: Axel Lin
---
arch/powerpc/cpu/mpc85xx/mpc8536_serdes.c | 4 ++--
arch/powerpc/cpu/mpc85xx/mpc8544_serdes.c | 4 ++--
arch/powerpc/cpu/mpc85xx/mpc8548_serdes.c | 2 +-
arch/powerpc/cpu/mp
Signed-off-by: Axel Lin
---
drivers/spi/armada100_spi.c | 11 ++-
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/drivers/spi/armada100_spi.c b/drivers/spi/armada100_spi.c
index afdbe05..b237c7c 100644
--- a/drivers/spi/armada100_spi.c
+++ b/drivers/spi/armada100_spi.c
Signed-off-by: Axel Lin
---
Forgot to CC mailing list, so here is a resend.
drivers/spi/tegra114_spi.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/spi/tegra114_spi.c b/drivers/spi/tegra114_spi.c
index b11a0a1..4d2af48 100644
--- a/drivers/spi/tegra114_spi.c
It's done in spi_alloc_slave(), thus remove the redundant code.
Signed-off-by: Axel Lin
---
drivers/spi/tegra20_sflash.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/spi/tegra20_sflash.c b/drivers/spi/tegra20_sflash.c
index 9322ce7..7c3a3fc 100644
--- a/driver
This change slightly improves readability.
Signed-off-by: Axel Lin
---
drivers/spi/cf_qspi.c | 2 +-
drivers/spi/mxc_spi.c | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/spi/cf_qspi.c b/drivers/spi/cf_qspi.c
index a37ac4e..06bcf91 100644
--- a/drivers/spi
at appropriate places
I was thinking doing so may add maintainer's burden. (well for this
case with 2 patches, it's not a problem)
But since you prefer sending a fix per driver, I'll resend the patches.
>
> On Fri, Jun 14, 2013 at 1:29 PM, Axel Lin wrote:
>> This change sl
This change slightly improves readability.
Signed-off-by: Axel Lin
---
drivers/spi/cf_qspi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/spi/cf_qspi.c b/drivers/spi/cf_qspi.c
index a37ac4e..06bcf91 100644
--- a/drivers/spi/cf_qspi.c
+++ b/drivers/spi/cf_qspi.c
This change slightly improves readability.
Signed-off-by: Axel Lin
---
drivers/spi/mxc_spi.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/mxc_spi.c b/drivers/spi/mxc_spi.c
index 5bed858..2ea3228 100644
--- a/drivers/spi/mxc_spi.c
+++ b/drivers/spi
Hi,
While reading the code in cfspi_tx():
while ((dspi->sr & 0xF000) >= 4) ;
I don't see the point of checking "(dspi->sr & 0xF000) >= 4)".
I'm wondering if it should be
while ((dspi->sr & 0xF000) >> 12) >= 4) ;
or simply
while (dspi->sr & 0xF000) ;
Curren
The implementation of gpio_is_valid() has inversed logic, fix it.
Signed-off-by: Axel Lin
---
Hi,
I don't have this hardware to test, but current code looks obviously wrong.
I'd appreciate if someone can review and test this patch.
Axel
drivers/gpio/altera_pio.c | 4 ++--
1 file
Current code had writel arguments the wrong way around, fix it.
Signed-off-by: Axel Lin
---
Hi,
I don't have this hardware to test, but current code looks obviously wrong.
I'd appreciate if someone can review and test this patch.
Axel
drivers/gpio/s3c2440_gpio.c | 6 +++---
1 file
Call s5p_gpio_set_value() to avoid code duplication.
Signed-off-by: Axel Lin
---
drivers/gpio/s5p_gpio.c | 9 +
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/drivers/gpio/s5p_gpio.c b/drivers/gpio/s5p_gpio.c
index 656bf4a..4efb768 100644
--- a/drivers/gpio/s5p_gpio.c
Current code looks strange because no matter the value argument is 0 or 1
it always calls
writel(1 << gpio, ®s->gpiodata[DATA_REG_ADDR(gpio)]);
And then gpio_get_value() always return 1.
I'm wondering if it needs to be fixed, something like below change:
diff --git a/drivers/gpio/spear_g
2013/6/19 Marek Vasut :
> Dear Axel Lin,
>
>> Current code looks strange because no matter the value argument is 0 or 1
>> it always calls
>> writel(1 << gpio, ®s->gpiodata[DATA_REG_ADDR(gpio)]);
>>
>> And then gpio_get_value() always return 1
check_gpio() and gpio_is_valid() are both used to check if a gpio is valid or
not. It looks pointless to have both function because we can just call
gpio_is_valid() instead of check_gpio(). Thus remove check_gpio() function.
Signed-off-by: Axel Lin
---
drivers/gpio/omap_gpio.c | 19
In current gpio_set_value() implementation, it always sets the gpio control bit
no matter the value argument is 0 or 1. Thus the GPIOs never set to low.
This patch fixes this bug.
Signed-off-by: Axel Lin
---
drivers/gpio/spear_gpio.c | 5 -
1 file changed, 4 insertions(+), 1 deletion
2013/6/20 Nikita Kiryanov
> Hi Axel,
>
>
> On 06/20/2013 04:03 AM, Axel Lin wrote:
>
>> check_gpio() and gpio_is_valid() are both used to check if a gpio is
>> valid or
>> not. It looks pointless to have both function because we can just call
>> gpio_i
2013/6/20 Marek Vasut
>
> Dear Axel Lin,
>
> > In current gpio_set_value() implementation, it always sets the gpio control
> > bit no matter the value argument is 0 or 1. Thus the GPIOs never set to
> > low. This patch fixes this bug.
> >
> > Signed-off-
AM33XX has 4 gpio banks, thus the valid gpio range should be 0 ... 127.
Signed-off-by: Axel Lin
---
drivers/gpio/omap_gpio.c | 4
1 file changed, 4 insertions(+)
diff --git a/drivers/gpio/omap_gpio.c b/drivers/gpio/omap_gpio.c
index a30d7f0..9aa6d41 100644
--- a/drivers/gpio/omap_gpio.c
AM33XX has 4 gpio banks, thus the valid gpio range should be 0 ... 127.
Signed-off-by: Axel Lin
---
v2: define OMAP_MAX_GPIO and use it.
This change is mainly based on Stefan's comment, however I use
OMAP_MAX_GPIO instead of CONFIG_OMAP_MAX_GPIO because having CONFIG_ prefix
seems meaning i
2013/6/21 Lubomir Popov :
> Hi Axel,
>
> On 21/06/13 06:07, Axel Lin wrote:
>> AM33XX has 4 gpio banks, thus the valid gpio range should be 0 ... 127.
>>
>> Signed-off-by: Axel Lin
>> ---
>> v2: define OMAP_MAX_GPIO and use it.
>> This change is ma
AM33XX has 4 gpio banks, thus the valid gpio range should be 0 ... 127.
Signed-off-by: Axel Lin
Acked-by: Stefan Roese
---
v2: define OMAP_MAX_GPIO and use it.
v3: no change, just for adding patch 2/2.
drivers/gpio/omap_gpio.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff
: Axel Lin
---
v3: just a new patch adding to this patch serial.
Hi Lubomir,
I'd appreciate if you can test this patch serial ( mainly for OMAP5 ).
Thanks,
Axel
arch/arm/cpu/armv7/omap5/hwinit.c | 4 +++-
arch/arm/include/asm/arch-omap5/gpio.h | 2 ++
drivers/gpio/omap_gpio.c
2013/6/21 Heiko Schocher :
> Hello Lubomir,
>
> Am 21.06.2013 09:44, schrieb Lubomir Popov:
>> One more thing that perhaps seems more reasonable in general:
>>
>> These OMAP_MAX_GPIO defines could go into the corresponding .../arch-omap*.h
>> files, where the base addresses are defined, and the num
OMAP54XX and DRA7XX SoCs have 8 banks per 32 GPIOs, that is, 256 in total.
Fix the gpio bank setting.
Signed-off-by: Axel Lin
---
arch/arm/cpu/armv7/omap5/hwinit.c | 4 +++-
arch/arm/include/asm/arch-omap5/gpio.h | 2 ++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/arch
Now the omap_gpio driver is used by AM33XX, OMAP3/4, OMAP54XX and DRA7XX SoCs.
These SoCs have various gpio count. Thus introduce get_omap_gpio_count()
function to get correct gpio count.
Signed-off-by: Axel Lin
---
arch/arm/cpu/armv7/am33xx/board.c | 5 +
arch/arm/cpu/armv7/omap3/board.c
. Update gpio bank settings and enable GPIO modules 7 & 8 clocks for OMAP5.
Thanks for Lubomir Popov to provide valuable comments to fix this issue.
Signed-off-by: Axel Lin
---
This patch supersedes below patches:
[PATCH v3 1/2] gpio: omap_gpio: Fix valid gpio range for AM33XX [1]
[PATCH v3 2/2]
Signed-off-by: Axel Lin
---
drivers/gpio/pca953x.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/gpio/pca953x.c b/drivers/gpio/pca953x.c
index be13745..7371cd4 100644
--- a/drivers/gpio/pca953x.c
+++ b/drivers/gpio/pca953x.c
@@ -47,9 +47,6 @@ struct
Signed-off-by: Axel Lin
---
common/cmd_i2c.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/common/cmd_i2c.c b/common/cmd_i2c.c
index 4380794..3215644 100644
--- a/common/cmd_i2c.c
+++ b/common/cmd_i2c.c
@@ -120,8 +120,6 @@ static uchar i2c_no_probes
Signed-off-by: Axel Lin
---
drivers/serial/serial.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/serial/serial.c b/drivers/serial/serial.c
index daa8003..a19cec5 100644
--- a/drivers/serial/serial.c
+++ b/drivers/serial/serial.c
@@ -37,7 +37,6 @@ static struct
Signed-off-by: Axel Lin
---
drivers/hwmon/lm63.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/hwmon/lm63.c b/drivers/hwmon/lm63.c
index f3adf64..bb8e644 100644
--- a/drivers/hwmon/lm63.c
+++ b/drivers/hwmon/lm63.c
@@ -133,8 +133,7 @@ int dtt_init_one(int sensor
Signed-off-by: Axel Lin
---
drivers/mtd/cfi_flash.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c
index 25f8752..a13b0b8 100644
--- a/drivers/mtd/cfi_flash.c
+++ b/drivers/mtd/cfi_flash.c
@@ -1797,7 +1797,7 @@ static
Signed-off-by: Axel Lin
---
drivers/usb/musb/musb_hcd.c | 3 +--
drivers/usb/musb/musb_udc.c | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/musb/musb_hcd.c b/drivers/usb/musb/musb_hcd.c
index 60e03a4..7bb91e5 100644
--- a/drivers/usb/musb/musb_hcd.c
+++ b
2013/6/25 Simon Glass :
> On Sat, Jun 22, 2013 at 6:56 AM, Axel Lin wrote:
>>
>> Signed-off-by: Axel Lin
>
>
> Missing commit message?
Because the subject line is already very clear.
And tools/checkpatch.pl does not complaint.
>
> Otherw
In special_gpio_free(), call unreserve() rather than reserve() to release gpio.
Signed-off-by: Axel Lin
---
arch/blackfin/cpu/gpio.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/blackfin/cpu/gpio.c b/arch/blackfin/cpu/gpio.c
index f74a0b7..a4d10d5 100644
--- a
In special_gpio_free(), call unreserve() rather than reserve() to release gpio.
Signed-off-by: Axel Lin
---
drivers/gpio/adi_gpio2.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpio/adi_gpio2.c b/drivers/gpio/adi_gpio2.c
index 7a034eb..051073c 100644
--- a
(function << offset);.
Signed-off-by: Axel Lin
---
arch/blackfin/cpu/gpio.c | 11 ++-
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/arch/blackfin/cpu/gpio.c b/arch/blackfin/cpu/gpio.c
index f74a0b7..c4cddaf 100644
--- a/arch/blackfin/cpu/gpio.c
+++ b/arch/blackfin/c
ast [enabled by default]
include/vsprintf.h:27:7: note: expected 'const char *' but argument is of type
'unsigned int'
This patch moves the code using gd->baudrate to be after init_baudrate() call,
this ensures we get the baudrate setting before using it.
Signed-off-by: Axel Lin
2013/6/29 Marek Vasut :
> Dear Axel Lin,
>
>> Current code uses gd->baudrate before setting its value.
>> Besides, I got below build warning which is introduced by
>> commit ddb5c5be "blackfin: add baudrate to bdinfo".
>>
>> board.c:235:3: warn
Use ARRAY_SIZE instead of having similar implementation in each drivers.
Signed-off-by: Axel Lin
Cc: Albert Aribaud
Cc: Ben Warren
Cc: Jean-Christophe PLAGNIOL-VILLARD
Cc: Joe Hershberger
Cc: Marek Vasut
Cc: Mike Frysinger
Cc: Nobuhiro Iwamatsu
Cc: TsiChungLiew
Cc: Wolfgang Denk
Cc
2013/6/30 Marek Vasut :
> Dear Axel Lin,
>
>> Use ARRAY_SIZE instead of having similar implementation in each drivers.
>>
>> Signed-off-by: Axel Lin
>> Cc: Albert Aribaud
>> Cc: Ben Warren
>> Cc: Jean-Christophe PLAGNIOL-VILLARD
>> Cc: Joe Hershb
Use ARRAY_SIZE instead of having similar implementation in each drivers.
Signed-off-by: Axel Lin
Cc: Albert Aribaud
Cc: Ben Warren
Cc: Jean-Christophe PLAGNIOL-VILLARD
Cc: Joe Hershberger
Cc: Marek Vasut
Cc: Mike Frysinger
Cc: Nobuhiro Iwamatsu
Cc: TsiChungLiew
Cc: Wolfgang Denk
Cc
>> diff --git a/drivers/net/npe/include/IxOsalTypes.h
>> b/drivers/net/npe/include/IxOsalTypes.h index 06e71de..615c655 100644
>> --- a/drivers/net/npe/include/IxOsalTypes.h
>> +++ b/drivers/net/npe/include/IxOsalTypes.h
>> @@ -93,7 +93,7 @@ typedef volatile INT32 VINT32;
>>
>>
>> #ifndef NUMELEMS
2013/6/21 Michael Trimarchi :
> On 06/21/2013 06:40 AM, Vipin Kumar wrote:
>> On 6/20/2013 7:26 PM, Axel Lin wrote:
>>> 2013/6/20 Marek Vasut
>>>>
>>>> Dear Axel Lin,
>>>>
>>>>> In current gpio_set_value() implementation,
There is no user calling this function, thus remove it.
Signed-off-by: Axel Lin
---
drivers/gpio/spear_gpio.c | 5 -
1 file changed, 5 deletions(-)
diff --git a/drivers/gpio/spear_gpio.c b/drivers/gpio/spear_gpio.c
index d3c728e..5b5521e 100644
--- a/drivers/gpio/spear_gpio.c
+++ b/drivers
2013/6/30 Michael Trimarchi :
> Hi
> Il giorno 30/giu/2013 06:18, "Axel Lin" ha scritto:
>
>
>>
>> 2013/6/21 Michael Trimarchi :
>> > On 06/21/2013 06:40 AM, Vipin Kumar wrote:
>> >> On 6/20/2013 7:26 PM, Axel Lin wrote:
>
2013/7/1 Sonic Zhang :
> Hi Axel,
>
> On Sat, Jun 29, 2013 at 8:34 AM, Axel Lin wrote:
>> Current code uses gd->baudrate before setting its value.
>> Besides, I got below build warning which is introduced by
>> commit ddb5c5be "blackfin: add baudrate to bd
ast [enabled by default]
include/vsprintf.h:27:7: note: expected 'const char *' but argument is of type
'unsigned int'
This patch ensures we get the baudrate setting before using it.
Signed-off-by: Axel Lin
---
v2: The change is based on Sonic 's suggestion:
move "gd
>
> The questions raised here are valid and it forced me to re-read the
> datasheet. For your convenience, I must tell you that the device is actually
> pl061 from ARM, so the driver can also be named so.
>
> The datasheet is here
> http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi019
>>> diff --git a/drivers/net/npe/IxEthDBFeatures.c
>>> b/drivers/net/npe/IxEthDBFeatures.c
>>> index c5b680a..d43efaa 100644
>>> --- a/drivers/net/npe/IxEthDBFeatures.c
>>> +++ b/drivers/net/npe/IxEthDBFeatures.c
>>> @@ -143,22 +143,22 @@ void ixEthDBFeatureCapabilityScan(void)
>>>
Use ARRAY_SIZE instead of having similar implementation in each drivers.
The NUMELEMS defined in drivers/net/npe/include/IxOsalTypes.h is not used
at all, so this patch removes it instead of converting it to use ARRAY_SIZE.
Signed-off-by: Axel Lin
Cc: Albert Aribaud
Cc: Ben Warren
Cc: Jean
Hi Macpaul,
For the case CONFIG_FTTMR010_EXT_CLK is not defined:
In reset_timer_masked():
lastdec = readl(&tmr->timer3_counter) / (CONFIG_SYS_CLK_FREQ / 2);
In get_timer_masked():
ulong now = readl(&tmr->timer3_counter) / (CONFIG_SYS_CLK_FREQ / 2 / 1024);
The code looks strange.
(Why one needs
uot; and "now" should be in millisecond,
thus fix the equation to set lastdec and now variables accordingly.
Signed-off-by: Axel Lin
---
Hi Kuan-Yu,
This change is based on your suggestion.
I don't have this hardware, can you test if this patch works?
Thanks,
Axel
arch/nds32/cpu/n1213
Use DIV_ROUND_UP to simplify the code.
Signed-off-by: Axel Lin
---
drivers/spi/bfin_spi.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/spi/bfin_spi.c b/drivers/spi/bfin_spi.c
index a9a4d92..f7192c2 100644
--- a/drivers/spi/bfin_spi.c
+++ b/drivers/spi
Use DIV_ROUND_UP to simplify the code.
Signed-off-by: Axel Lin
---
drivers/spi/fsl_espi.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/spi/fsl_espi.c b/drivers/spi/fsl_espi.c
index 28609ee..e20ab9f 100644
--- a/drivers/spi/fsl_espi.c
+++ b/drivers/spi
Use DIV_ROUND_UP to simplify the code.
Signed-off-by: Axel Lin
---
drivers/spi/mpc8xxx_spi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/spi/mpc8xxx_spi.c b/drivers/spi/mpc8xxx_spi.c
index 6b0e3b4..c90c0ce 100644
--- a/drivers/spi/mpc8xxx_spi.c
+++ b/drivers/spi
2013/7/1 Sonic Zhang :
> Acked-by: Sonic Zhang
hi Sonic,
I thought you will pick up this patch, but now I got your ACK and I have
no idea who will take this patch.
Just wondering if this patch should be applied for v2013.07?
Regards,
Axel
___
U-Boot ma
We have a sh_spi_clear_bit() function, there's no reason not to use it.
Signed-off-by: Axel Lin
---
drivers/spi/sh_spi.c | 10 ++
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/drivers/spi/sh_spi.c b/drivers/spi/sh_spi.c
index 744afe3..7ca5e36 100644
--- a/driver
Currently we have similar code for (txp && rxp), (txp && !rxp), (!rxp & txp),
and (!txp && !rxp) cases. This patch refactors the code a bit to avoid
duplicate similar code.
Signed-off-by: Axel Lin
---
Hi Thomas,
This path is similar to the patch I sent for spi
Fix build error due to missing include of serial.h and a trivial typo.
Signed-off-by: Axel Lin
---
drivers/serial/opencores_yanu.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/serial/opencores_yanu.c b/drivers/serial/opencores_yanu.c
index 8de2eca..80e9ae5
The implementation of oc_serial_setbrg() for CONFIG_SYS_NIOS_FIXEDBAUD and
!CONFIG_SYS_NIOS_FIXEDBAUD are very similar.
Add a baudrate variable and set it to either CONFIG_BAUDRATE or gd->baudrate.
Then we can unify the code for both cases.
Signed-off-by: Axel Lin
---
drivers/ser
The implementation of oc_serial_setbrg() for CONFIG_SYS_NIOS_FIXEDBAUD and
!CONFIG_SYS_NIOS_FIXEDBAUD are very similar.
Add a baudrate variable and set it to either CONFIG_BAUDRATE or gd->baudrate.
Then we can unify the code for both cases.
Signed-off-by: Axel Lin
---
drivers/ser
Fix build error due to missing include of serial.h and a trivial typo.
Signed-off-by: Axel Lin
---
Hi Tom,
This patch was sent on
http://lists.denx.de/pipermail/u-boot/2014-January/171093.html
I don't get any feedback from NIOS2 maintainers so far.
Maybe you can pick up this serial
(or at
Use dev_get_priv() rather than dev_get_platdata() to get correct address of
private data.
Signed-off-by: Axel Lin
---
Hi Simon,
I don't have this h/w, so please test if you think this patch is ok.
Thanks,
Axel
drivers/gpio/at91_gpio.c | 10 +-
1 file changed, 5 insertions(
Use dev_get_priv() rather than dev_get_platdata() to get correct address of
private data.
Signed-off-by: Axel Lin
---
v2: Fix an obvious typo in subject line (s/addres/address).
drivers/gpio/at91_gpio.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/gpio
Pass bank rather than bank->base to _get_gpio_direction().
Signed-off-by: Axel Lin
---
drivers/gpio/omap_gpio.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/omap_gpio.c b/drivers/gpio/omap_gpio.c
index f3a7ccb..19fc451 100644
--- a/drivers/gpio/omap_gpi
Signed-off-by: Axel Lin
---
common/image-fit.c | 4 +---
common/image-sig.c | 16
2 files changed, 5 insertions(+), 15 deletions(-)
diff --git a/common/image-fit.c b/common/image-fit.c
index b47d110..778d2a1 100644
--- a/common/image-fit.c
+++ b/common/image-fit.c
@@ -1010,9
Use fdt_for_each_subnode macro to simplify the code a bit.
Signed-off-by: Axel Lin
---
v2: Update commit log
common/image-fit.c | 4 +---
common/image-sig.c | 16
2 files changed, 5 insertions(+), 15 deletions(-)
diff --git a/common/image-fit.c b/common/image-fit.c
index
Don't assume slave is always the first member of struct ftssp010_spi.
Use to_ftssp010_spi() to ensure free correct address in spi_free_slave().
Signed-off-by: Axel Lin
---
drivers/spi/ftssp010_spi.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/driver
Don't assume slave is always the first member of struct cf_spi_slave.
Use container_of instead of casting first structure member.
Signed-off-by: Axel Lin
---
drivers/spi/cf_spi.c | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/cf_spi.c b/driver
Make local functions static and remove unneeded forward declarations.
Signed-off-by: Axel Lin
---
drivers/spi/cf_spi.c | 20 +++-
1 file changed, 7 insertions(+), 13 deletions(-)
diff --git a/drivers/spi/cf_spi.c b/drivers/spi/cf_spi.c
index 7453538..6ce1101 100644
--- a
Use default_serial_puts() instead of duplicating the implementation.
Signed-off-by: Axel Lin
---
drivers/serial/serial_arc.c | 8 +---
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/serial/serial_arc.c b/drivers/serial/serial_arc.c
index e63d25d..fd56ca3 100644
--- a
Refactor the code a bit to make it better in readability.
Remove the comments because now the intention of the code is pretty clear.
Signed-off-by: Axel Lin
---
drivers/spi/atmel_dataflash_spi.c | 31 ---
1 file changed, 12 insertions(+), 19 deletions(-)
diff --git
riv
data. Thus this patch renames lpc32xx_gpio_platdata to lpc32xx_gpio_priv
and converts all dev_get_platdata() to dev_get_priv().
Signed-off-by: Axel Lin
---
Hi Albert,
I don't have this h/w for testing, so only compile test.
I'd appreciate if you can review and test this patch.
Thanks,
2015-04-13 16:41 GMT+08:00 Albert ARIBAUD :
> Hi Axel,
>
> Le Sat, 11 Apr 2015 10:20:08 +0800, Axel Lin a
> écrit :
>
>> Initially I found this driver has set priv_auto_alloc_size but it actually
>> never use dev->priv. The U_BOOT_DEVICE(lpc32xx_gpios) does not p
The LPC32XX GPIO driver platdata currently contains GPIO state information,
which should go into priv_data. Thus rename lpc32xx_gpio_platdata to
lpc32xx_gpio_priv and convert to use dev_get_priv() instead.
Signed-off-by: Axel Lin
---
v2: Update commit log to mention that using priv_data for
2015-04-22 2:26 GMT+08:00 Jagannadha Sutradharudu Teki
:
> Zap ftssp010_spi driver since the boards used this driver
> is no longer been active.
I'm not sure if this is correct thing to do...
It's fine to drop unmaintained boards, but a driver can/may be used by different
boards. So If someday the
Use clrsetbits_le32() to replace clrbits_le32() + setbits_le32().
Signed-off-by: Axel Lin
---
drivers/gpio/stm32_gpio.c | 15 ---
1 file changed, 4 insertions(+), 11 deletions(-)
diff --git a/drivers/gpio/stm32_gpio.c b/drivers/gpio/stm32_gpio.c
index d3497e9..76f7b1b 100644
--- a
Hi Simon,
Any reason that now using hard-coded "baud_divisor = 13;" in debug_uart_init()?
(The change is introduced by commit dd0b0122bac
serial: ns16550: Add an option to specify the debug UART register shift)
Regards,
Axel
___
U-Boot mailing list
U-Bo
This was accidentally added by commit dd0b0122bacc
"serial: ns16550: Add an option to specify the debug UART register shift".
Remove it.
Signed-off-by: Axel Lin
---
drivers/serial/ns16550.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/serial/ns16550.c b/drivers/serial
Use clrsetbits_le32() to replace clrbits_le32() + setbits_le32().
Signed-off-by: Axel Lin
---
v2: Conver one more place (updating &gpio_regs->afr[dsc->pin >> 3] register)
to use clrsetbits_le32().
drivers/gpio/stm32_gpio.c | 18 +-
1 file changed, 5 i
dm_gpio_set_dir_flags() will also set gpio output value when switching to
gpio output. So it's not necessary to call dm_gpio_set_value() after
dm_gpio_set_dir_flags() call.
Signed-off-by: Axel Lin
---
drivers/i2c/i2c-gpio.c | 13 +++--
1 file changed, 7 insertions(+), 6 dele
cpu_init_crit() can be skipped, but the code is still enabled requiring a
platform to supply lowlevel_init().
Signed-off-by: Axel Lin
---
arch/arm/cpu/arm720t/start.S | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/cpu/arm720t/start.S b/arch/arm/cpu/arm720t/start.S
index 9facc7e
2013/5/15 Albert ARIBAUD :
> Hi Marek,
>
> On Wed, 15 May 2013 05:36:14 +0200, Marek Vasut wrote:
>
>> Dear Axel Lin,
>>
>> > cpu_init_crit() can be skipped, but the code is still enabled requiring a
>> > platform to supply lowlevel_init().
>> &g
2013/5/15 Stephen Warren :
> On 05/14/2013 09:04 PM, Axel Lin wrote:
>> cpu_init_crit() can be skipped, but the code is still enabled requiring a
>> platform to supply lowlevel_init().
>
>> diff --git a/arch/arm/cpu/arm720t/start.S b/arch/arm/cpu/arm72
Then we can get rid of the #ifdef CONFIG_TEGRA guard in cpu_init_crit.
Signed-off-by: Axel Lin
---
Hi Stephen,
This patch is on top of
[PATCH] ARM: arm720t: Add missing CONFIG_SKIP_LOWLEVEL_INIT guard for
cpu_init_crit [1]
I make this as a separate patch because this patch is tegra specific
Then we can get rid of the #ifdef CONFIG_TEGRA guard in cpu_init_crit.
Signed-off-by: Axel Lin
Tested-by: Stephen Warren
---
arch/arm/cpu/arm720t/start.S| 2 --
include/configs/tegra-common-post.h | 2 ++
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm/cpu
cpu_init_crit() can be skipped, but the code is still enabled requiring a
platform to supply lowlevel_init().
Signed-off-by: Axel Lin
Tested-by: Stephen Warren
---
arch/arm/cpu/arm720t/start.S | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm/cpu/arm720t/start.S b/arch/arm/cpu
Add the missing bang (!) to execute external command, otherwise it does not
work.
Signed-off-by: Axel Lin
---
boards.cfg | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/boards.cfg b/boards.cfg
index dbd8479..9fc77fb 100644
--- a/boards.cfg
+++ b/boards.cfg
@@ -38,7 +38,7
2013/9/14 Albert ARIBAUD :
> Hi Axel,
>
> On Fri, 06 Sep 2013 14:22:40 +0800, Axel Lin
> wrote:
>
>> In current gpio_set_value() implementation, it always sets the gpio control
>> bit
>> no matter the value argument is 0 or 1. Thus the GPIOs never set to
bits without affecting any other pins in a
single write operation. Thus we don't need a read-modify-write to update the
register.
Signed-off-by: Axel Lin
Acked-by: Stefan Roese
Reviewed-by: Vipin Kumar
Reviewed-by: Michael Trimarchi
---
v2: Update commit log to explain why a read-modify-wri
Staticize local functions in mxs_auart driver.
Signed-off-by: Axel Lin
---
drivers/serial/mxs_auart.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/serial/mxs_auart.c b/drivers/serial/mxs_auart.c
index 7cfe5bc..fc0fa96 100644
--- a/drivers/serial
2013/10/15 Marek Vasut :
> Dear Axel Lin,
>
>> Staticize local functions in mxs_auart driver.
>>
>> Signed-off-by: Axel Lin
>
> Acked-by: Marek Vasut
>
> Just curious, how did you find this? Did you lint the files with some tool?
Staticize local functions in xuartlite driver.
Signed-off-by: Axel Lin
---
drivers/serial/serial_xuartlite.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/serial/serial_xuartlite.c
b/drivers/serial/serial_xuartlite.c
index 9c1d025..daaf155 100644
--- a
Staticize local functions in s5p serial driver.
Signed-off-by: Axel Lin
---
drivers/serial/serial_s5p.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/serial/serial_s5p.c b/drivers/serial/serial_s5p.c
index f98b422..13ced26 100644
--- a/drivers/serial
Staticize local functions in xuartlite driver.
Signed-off-by: Axel Lin
---
v2: Also staticize userial##port##_* functions
drivers/serial/serial_xuartlite.c | 20 ++--
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/serial/serial_xuartlite.c
b/drivers
Staticize local functions in s5p serial driver.
Signed-off-by: Axel Lin
---
v2: Also staticize s5p_serial##port##_* functions
drivers/serial/serial_s5p.c | 24
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/drivers/serial/serial_s5p.c b/drivers/serial
Fix a trivial copy-paste bug.
Signed-off-by: Axel Lin
---
drivers/spi/davinci_spi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/spi/davinci_spi.c b/drivers/spi/davinci_spi.c
index 28fb3a2..0ec5b9d 100644
--- a/drivers/spi/davinci_spi.c
+++ b/drivers/spi
Hi list,
I use "sf erase" + "sf write" commands to write root image to spi nor flash.
It works for writing a ext2 image.
However, if I use the same commands to write a jffs2 image I got a lot
of "Magic bitmask 0x1985 not found at..." messages and
"jffs2: inflate returned -3".
jffs2: jffs2_scan_er
2013/11/28 Axel Lin :
> Hi list,
>
> I use "sf erase" + "sf write" commands to write root image to spi nor flash.
> It works for writing a ext2 image.
> However, if I use the same commands to write a jffs2 image I got a lot
> of "Magic bitmask 0x1985 not
1 - 100 of 133 matches
Mail list logo