All M68K boards are broken
Subsystems (2)
cover All M68K boards are broken
Hello.
Even after applying the patch
"config.mk: fix -fstack-usage support test"
(http://patchwork.ozlabs.org/patch/283619/),
I still cannot compile m68k correctly.
The result of CROSS_COMPILE=m68k-linux- ./MAKEALL -a m68k is
--------------------- SUMMARY ----------------------------
Boards compiled: 50
Boards with errors: 6 ( M5253DEMO M54455EVB M54455EVB_a66
M54455EVB_i66 M54455EVB_intel M54455EVB_stm33 )
Boards with warnings but no errors: 44 ( M52277EVB
M52277EVB_stmicro M5235EVB M5235EVB_Flash32 idmr cobra5272
eb_cpu5282 eb_cpu5282_internal TASREG M5208EVBE M5249EVB
M5253EVBE M5271EVB M5272C3 M5275EVB M5282EVB astro_mcf5373l
M53017EVB M5329AFEE M5329BFEE M5373EVB M54418TWR
M54418TWR_nand_mii M54418TWR_nand_rmii M54418TWR_nand_rmii_lowfreq
M54418TWR_serial_mii M54418TWR_serial_rmii M54451EVB M54451EVB_stmicro
M5475AFE M5475BFE M5475CFE M5475DFE M5475EFE M5475FFE M5475GFE
M5485AFE M5485BFE M5485CFE M5485DFE M5485EFE M5485FFE M5485GFE M5485HFE )
----------------------------------------------------------I just took a look and
I found lots of files are left broken for a long term.
I pick up some them here.
(1) drivers/i2c/i2c_core.ci2c_core.c: In function 'i2c_reloc_fixup':
i2c_core.c:63:20: warning: assignment from incompatible pointer type [enabled by default] i2c_core.c:67:21: warning: assignment from incompatible pointer type [enabled by default] i2c_core.c:71:20: warning: assignment from incompatible pointer type [enabled by default] i2c_core.c:76:21: warning: assignment from incompatible pointer type [enabled by default] i2c_core.c:81:29: warning: assignment from incompatible pointer type [enabled by default]
(2) arch/m68k/lib/bootm.c
bootm.c:53:8: warning: unused variable 'rd_len' [-Wunused-variable]
bootm.c:99:12: warning: 'initrd_start' may be used uninitialized in this function [-Wuninitialized] bootm.c:99:12: warning: 'initrd_end' may be used uninitialized in this function [-Wuninitialized] bootm.c:99:12: warning: 'cmd_start' may be used uninitialized in this function [-Wuninitialized] bootm.c:99:12: warning: 'cmd_end' may be used uninitialized in this function [-Wuninitialized]
(3) arch/m68k/cpu/mcf5445x/cpu_init.c
cpu_init.c:367:21: warning: unused variable 'info' [-Wunused-variable]
(4)
cpu_init.c:48:2: warning: passing argument 1 of 'out_be32' from incompatible pointer type [enabled by default] arch/m68k/include/asm/io.h:207:20: note: expected 'volatile unsigned int *' but argument is of type 'u16 *' cpu_init.c:49:2: warning: passing argument 1 of 'out_be32' from incompatible pointer type [enabled by default] arch/m68k/include/asm/io.h:207:20: note: expected 'volatile unsigned int *' but argument is of type 'u16 *'
(5)include/configs/M5253DEMO.h:1:1: error: unknown type name 'TABILITY' include/configs/M5253DEMO.h:1:13: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'FITNESS' include/configs/M5253DEMO.h:1:13: error: unknown type name 'FITNESS' include/configs/M5253DEMO.h:2:2: error: stray '@' in program
(6)cpu_init.c: In function 'cpu_init_f':
cpu_init.c:211:10: warning: unused variable 'wdog' [-Wunused-variable]
(7)mcf5373l.c: In function 'initdram':
mcf5373l.c:83:5: warning: pointer targets in passing argument 1 of 'get_ram_size' differ in signedness [-Wpointer-sign] include/common.h:456:6: note: expected 'long int *' but argument is of type 'long unsigned int *'
(8)
fpga.c:168:2: warning: initialization from incompatible pointer type [enabled by default] fpga.c:168:2: warning: (near initialization for 'altera_fns.write') [enabled by default] fpga.c: In function 'astro5373l_altera_load':
fpga.c:196:20: warning: assignment from incompatible pointer type [enabled by default]
(9)speed.c: In function 'setup_5441x_clocks':
speed.c:118:2: warning: passing argument 1 of 'in_be16' makes pointer from integer without a cast [enabled by default] arch/m68k/include/asm/io.h:177:19: note: expected 'volatile u16 *' but argument is of type 'u16'
(10)
fsl_i2c.c:50:39: error: 'CONFIG_SYS_FSL_I2C_OFFSET' undeclared here (not in a function)
I began to fix some of them and I gave up on the way.
Who is the custodian of M68K?
I doubt M68K is maintained.
Masahiro Yamada (3):
i2c: eliminate warnings in i2c_reloc_fixup function
m68k: eliminate warnings in do_bootm_linux function
m68k: eliminate a warning in cpu_init
arch/m68k/cpu/mcf5445x/cpu_init.c | 2 +- arch/m68k/lib/bootm.c | 7 ++++++- drivers/i2c/i2c_core.c | 12 +++++------- 3 files changed, 12 insertions(+), 9 deletions(-)
Signature · 1 line
1.8.1.2
PATCH 1/3 i2c: eliminate warnings in i2c_reloc_fixup function
The prototype of handlers had changed.
This commit uses cast with (void *) rather than
the handler-specific prototype.
---
Note:
The body of i2c_reloc_fixup function is surrounded by
#if defined(CONFIG_NEEDS_MANUAL_RELOC) ... #endif
avr32, m68k, nds32, sparc defines this macro.
drivers/i2c/i2c_core.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-)
drivers/i2c/i2c_core.c +5 -7
@@ -60,25 +60,23 @@ void i2c_reloc_fixup(void)/* i2c_init() */ addr = (unsigned long )i2c_adap_p->init; addr += gd->reloc_off; - i2c_adap_p->init = (void (*)(int ,int ))addr; + i2c_adap_p->init = (void *)addr;/* i2c_probe() */ addr = (unsigned long )i2c_adap_p->probe; addr += gd->reloc_off; - i2c_adap_p->probe = (int (*)(uint8_t ))addr; + i2c_adap_p->probe = (void *)addr;/* i2c_read() */ addr = (unsigned long )i2c_adap_p->read; addr += gd->reloc_off; - i2c_adap_p->read = (int (*)(uint8_t ,uint ,int ,uint8_t *, -int ))addr; + i2c_adap_p->read = (void *)addr;/* i2c_write() */ addr = (unsigned long )i2c_adap_p->write; addr += gd->reloc_off; - i2c_adap_p->write = (int (*)(uint8_t ,uint ,int ,uint8_t *, -int ))addr; + i2c_adap_p->write = (void *)addr;/* i2c_set_bus_speed() */ addr = (unsigned long )i2c_adap_p->set_bus_speed; addr += gd->reloc_off; - i2c_adap_p->set_bus_speed = (uint (*)(uint ))addr; + i2c_adap_p->set_bus_speed = (void *)addr;/* name */ addr = (unsigned long )i2c_adap_p->name; addr += gd->reloc_off;
Signature · 1 line
1.8.1.2
PATCH 1/3 i2c: eliminate warnings in i2c_reloc_fixup function
Hello Masahiro,
Am 16.10.2013 06:53, schrieb Masahiro Yamada:
Quoted 11 lines
The prototype of handlers had changed.
This commit uses cast with (void *) rather than
the handler-specific prototype.Signed-off-by Masahiro Yamada<[email protected]>---
Note:
The body ofi2c_reloc_fixupfunction is surrounded by
#ifdefined(CONFIG_NEEDS_MANUAL_RELOC)... #endif
Quoted 5 lines
avr32, m68k, nds32, sparc defines this macro.
drivers/i2c/i2c_core.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-)
Applied to u-boot-i2c.git
Thanks!
bye,
Heiko
Signature · 2 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
PATCH 2/3 m68k: eliminate warnings in do_bootm_linux function
In reply to Masahiro Yamada - delete an unused variable
- set forcibly some variables to zero
---
*** CAUTION ***
I do not think I am doing right thing.
(I post this patch just to raise the flag.)
Experts of M68K architecture, please fix this correctly.
arch/m68k/lib/bootm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
arch/m68k/lib/bootm.c +6 -1
@@ -50,7 +50,6 @@ void arch_lmb_reserve(struct lmb *lmb)int do_bootm_linux (int flag,int argc,char *const argv[],bootm_headers_t *images) { -ulong rd_len;ulong initrd_start, initrd_end;int ret;
@@ -87,6 +86,12 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imabootstage_mark (BOOTSTAGE_ID_RUN_OS ); +/* Workaround to eliminate warnings: FIX ME */ + initrd_start =0 ; + initrd_end =0 ; + cmd_start =0 ; + cmd_end =0 ; +/* * Linux Kernel Parameters (passing board info data): * sp+00: Ignore, side effect of using jsr to jump to kernel
Signature · 1 line
1.8.1.2
PATCH 3/3 m68k: eliminate a warning in cpu_init
In reply to Masahiro Yamada--- arch/m68k/cpu/mcf5445x/cpu_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/m68k/cpu/mcf5445x/cpu_init.c +1 -1
@@ -364,9 +364,9 @@ void uart_port_conf(int port)int fecpin_setclear (struct eth_device *dev,int setclear) {gpio_t *gpio = (gpio_t *)MMAP_GPIO ; +#ifdef CONFIG_MCF5445xstruct fec_info_s *info = (struct fec_info_s *)dev->priv; -#ifdef CONFIG_MCF5445xif (setclear) {#ifdef CONFIG_SYS_FEC_NO_SHARED_PHY if (info->iobase ==CONFIG_SYS_FEC0_IOBASE )
Signature · 1 line
1.8.1.2
PATCH 3/3 m68k: eliminate a warning in cpu_init
Quoted 1 line · Masahiro Yamada
Signed-off-by Masahiro Yamada <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140619/a95ed560/attachment.pgp>
cover All M68K boards are broken
In reply to Masahiro YamadaHi Masahiro,
Quoted 6 lines · Masahiro Yamada
Hello.
Even after applying the patch
"config.mk: fix -fstack-usage support test"
(http://patchwork.ozlabs.org/patch/283619/),
I still cannot compile m68k correctly.
Patch 283691 has not been applied and won't be since it breaks builds; therefore, to fix this, rather than submitting this new patch, please provide a new and fixed version (v5) of the existing one.
Amicalement,
Signature · 1 line
Albert.
cover All M68K boards are broken
Hello Albert.
Quoted 8 lines
Quoted 4 lines
Even after applying the patch
"config.mk: fix -fstack-usage support test"
(http://patchwork.ozlabs.org/patch/283619/),
I still cannot compile m68k correctly.Patch 283691 has not been applied and won't be since it breaks builds; therefore, to fix this, rather than submitting this new patch, please provide a new and fixed version (v5) of the existing one.
Sorry, I could not understand what you mean.
I think Patch 283691 does not break builds, but fixes -fstack-usage related warnings on Blackfin, M68K, etc.
What I mean is:
Patch 283619 makes it better,
but we still have lots of other errors/warnings.
Best Regards
Masahiro Yamada
cover All M68K boards are broken
Hi Masahiro,
Quoted 14 lines · Masahiro Yamada
Hello Albert.
Quoted 8 lines
Quoted 4 lines
Even after applying the patch
"config.mk: fix -fstack-usage support test"
(http://patchwork.ozlabs.org/patch/283619/),
I still cannot compile m68k correctly.Patch 283691 has not been applied and won't be since it breaks builds; therefore, to fix this, rather than submitting this new patch, please provide a new and fixed version (v5) of the existing one.
Sorry, I could not understand what you mean.
Quoted 7 lines
I think Patch 283691 does not break builds, but fixes -fstack-usage related warnings on Blackfin, M68K, etc.
What I mean is:
Patch 283619 makes it better,
but we still have lots of other errors/warnings.
That's what I understood too; and the way you said it, I thought this patch series was an improvement on 283619. If it is unrelated, then ignore my comment.
Quoted 2 lines
Best Regards
Masahiro Yamada
Amicalement,
Signature · 1 line
Albert.
cover All M68K boards are broken
Hello Albert
Quoted 1 line
If it is unrelated, then ignore my comment.
Yes.
They are totally unrelated.
Quoted 4 lines
Even after applying the patch
"config.mk: fix -fstack-usage support test"
(http://patchwork.ozlabs.org/patch/283619/),
I still cannot compile m68k correctly.
I should have dropped this comment.
It looks like it was confusing...
Best Regards
Masahiro Yamada