linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: firmware build failure
@ 2008-06-06  7:47 Stephen Rothwell
  2008-06-06  9:09 ` David Woodhouse
  2008-06-06  9:31 ` David Woodhouse
  0 siblings, 2 replies; 10+ messages in thread
From: Stephen Rothwell @ 2008-06-06  7:47 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-next

[-- Attachment #1: Type: text/plain, Size: 455 bytes --]

Hi David,

Today's linux-next build (x86_64 allmodconfig) failed like this:

  IHEX2FW firmware/atmsar11.fw
Bad EOF record (type 01) format
make[2]: *** [firmware/atmsar11.fw] Error 1

I reverted the obvious candidate - commit
62836d89ead6bd0502cb56b31ebccae818db157f ("firmware: convert Ambassador
ATM driver to request_firmware()").

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]

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

* Re: linux-next: firmware build failure
  2008-06-06  7:47 linux-next: firmware build failure Stephen Rothwell
@ 2008-06-06  9:09 ` David Woodhouse
  2008-06-06  9:31 ` David Woodhouse
  1 sibling, 0 replies; 10+ messages in thread
From: David Woodhouse @ 2008-06-06  9:09 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next

On Fri, 2008-06-06 at 17:47 +1000, Stephen Rothwell wrote:
> Today's linux-next build (x86_64 allmodconfig) failed like this:
> 
>   IHEX2FW firmware/atmsar11.fw
> Bad EOF record (type 01) format
> make[2]: *** [firmware/atmsar11.fw] Error 1

Dammit, and I thought I was going to manage a whole day without breaking
the build. Sorry; will attend to it now...

-- 
dwmw2


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

* Re: linux-next: firmware build failure
  2008-06-06  7:47 linux-next: firmware build failure Stephen Rothwell
  2008-06-06  9:09 ` David Woodhouse
@ 2008-06-06  9:31 ` David Woodhouse
  1 sibling, 0 replies; 10+ messages in thread
From: David Woodhouse @ 2008-06-06  9:31 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next

On Fri, 2008-06-06 at 17:47 +1000, Stephen Rothwell wrote:
> Hi David,
> 
> Today's linux-next build (x86_64 allmodconfig) failed like this:
> 
>   IHEX2FW firmware/atmsar11.fw
> Bad EOF record (type 01) format
> make[2]: *** [firmware/atmsar11.fw] Error 1

Bah. The actual fix is something like this, which I forgot to commit.
Sorry again -- it's there now (with some more minor cleanups).

--- a/firmware/ihex2fw.c
+++ b/firmware/ihex2fw.c
@@ -146,7 +146,6 @@ next_record:
 
        record->addr  = hex(data + i, &crc) << 8; i += 2;
        record->addr |= hex(data + i, &crc); i += 2;
-       record->addr += offset;
        type = hex(data + i, &crc); i += 2;
 
        for (j = 0; j < record->len; j++, i += 2)
@@ -166,12 +165,13 @@ next_record:
                if (!record->len)
                        break;
 
+               record->addr += offset;
                file_record(record);
                goto next_record;
 
        case 1: /* End-Of-File Record */
                if (record->addr || record->len) {
                        fprintf(stderr, "Bad EOF record (type 01) format\n");


> 
-- 
dwmw2


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

* Re: linux-next: firmware build failure
  2008-06-12  6:28 Stephen Rothwell
@ 2008-06-12  8:54 ` David Woodhouse
  0 siblings, 0 replies; 10+ messages in thread
From: David Woodhouse @ 2008-06-12  8:54 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next

On Thu, 2008-06-12 at 16:28 +1000, Stephen Rothwell wrote:
> 
> 
> Today's linux-next build (x86_64 allmodconfig) failed like this:
> 
> drivers/char/ip2/ip2main.c: In function 'ip2_request_firmware':
> drivers/char/ip2/ip2main.c:483: error: implicit declaration of function 'platform_device_register_simple'
> drivers/char/ip2/ip2main.c:483: warning: assignment makes pointer from integer without a cast
> drivers/char/ip2/ip2main.c:486: error: dereferencing pointer to incomplete type
> drivers/char/ip2/ip2main.c:490: error: implicit declaration of function 'platform_device_unregister'
> 
> I applied the patch below.

Oops, sorry about that. We get <linux/platform_device.h> included for us
on PowerPC, it seems. Have fixed.

-- 
dwmw2


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

* linux-next: firmware build failure
@ 2008-06-12  6:28 Stephen Rothwell
  2008-06-12  8:54 ` David Woodhouse
  0 siblings, 1 reply; 10+ messages in thread
From: Stephen Rothwell @ 2008-06-12  6:28 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-next

Hi David,

Today's linux-next build (x86_64 allmodconfig) failed like this:

drivers/char/ip2/ip2main.c: In function 'ip2_request_firmware':
drivers/char/ip2/ip2main.c:483: error: implicit declaration of function 'platform_device_register_simple'
drivers/char/ip2/ip2main.c:483: warning: assignment makes pointer from integer without a cast
drivers/char/ip2/ip2main.c:486: error: dereferencing pointer to incomplete type
drivers/char/ip2/ip2main.c:490: error: implicit declaration of function 'platform_device_unregister'

I applied the patch below.
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

>From 8cf424dac01282d3e8a4041f27c6de6a15a47823 Mon Sep 17 00:00:00 2001
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Thu, 12 Jun 2008 16:25:34 +1000
Subject: [PATCH] firmware: fix ip2 conversion fallout

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 drivers/char/ip2/ip2main.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/char/ip2/ip2main.c b/drivers/char/ip2/ip2main.c
index 1199a2b..e8a4d16 100644
--- a/drivers/char/ip2/ip2main.c
+++ b/drivers/char/ip2/ip2main.c
@@ -100,6 +100,7 @@
 #include <linux/device.h>
 #include <linux/smp_lock.h>
 #include <linux/firmware.h>
+#include <linux/platform_device.h>
 
 #include <linux/tty.h>
 #include <linux/tty_flip.h>
-- 
1.5.5.4


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

* Re: linux-next: firmware build failure
  2008-06-04  9:53 ` David Woodhouse
@ 2008-06-04 10:47   ` Stephen Rothwell
  0 siblings, 0 replies; 10+ messages in thread
From: Stephen Rothwell @ 2008-06-04 10:47 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-next

[-- Attachment #1: Type: text/plain, Size: 327 bytes --]

Hi David,

On Wed, 04 Jun 2008 10:53:38 +0100 David Woodhouse <dwmw2@infradead.org> wrote:
>
> OK, both those should be fixed in the firmware-2.6.git tree now; thanks.

They will be in tomorrow's tree.

Thanks.
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: linux-next: firmware build failure
  2008-06-04  9:22 ` David Woodhouse
@ 2008-06-04 10:40   ` Stephen Rothwell
  0 siblings, 0 replies; 10+ messages in thread
From: Stephen Rothwell @ 2008-06-04 10:40 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-next

[-- Attachment #1: Type: text/plain, Size: 1250 bytes --]

Hi David,

On Wed, 04 Jun 2008 10:22:57 +0100 David Woodhouse <dwmw2@infradead.org> wrote:
>
> On Wed, 2008-06-04 at 16:46 +1000, Stephen Rothwell wrote:
> > -                 echo "    .align $(ASM_ALIGN)"                        >>$@;\
> > +                 echo "    .p2align $${ASM_ALIGN}"                     >>$@;\
> 
> Ah, thanks. I did originally start doing it with big C files with char
> arrays, which made this part easier -- but I really wanted to
> use .incbin so I didn't have to copy the whole of the object into
> 'source' code. Just checking that that actually does the right thing on
> ppc and ppc64 too, and I'll refactor it to include that. And the kaweth
> fix.

Great, thanks.

> Then I'll go seeking the usb tree of which you speak, with the ti patch
> that conflicts. This not the tree at
> kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6.git labelled 'junk
> tree; please ignore', I assume?

It is a quilt series here:
http://kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/gregkh-04-usb/

All the trees and their sources are listed in the file Next/Trees in the
linux-next tree.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: linux-next: firmware build failure
  2008-06-04  6:46 Stephen Rothwell
  2008-06-04  9:22 ` David Woodhouse
@ 2008-06-04  9:53 ` David Woodhouse
  2008-06-04 10:47   ` Stephen Rothwell
  1 sibling, 1 reply; 10+ messages in thread
From: David Woodhouse @ 2008-06-04  9:53 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next

On Wed, 2008-06-04 at 16:46 +1000, Stephen Rothwell wrote:
> Hi David,
> 
> Today's linux-next build (x86_64 allmodconfig) failed like this:
> 
> firmware/whiteheat_loader.fw.gen.S: Assembler messages:
> firmware/whiteheat_loader.fw.gen.S:8: Error: alignment not a power of 2
> firmware/whiteheat_loader.fw.gen.S:12: Error: alignment not a power of 2

> Also:
> 
> drivers/net/usb/kaweth.c: In function 'kaweth_download_firmware':
> drivers/net/usb/kaweth.c:422: error: 'data' undeclared (first use in this function)

OK, both those should be fixed in the firmware-2.6.git tree now; thanks.

-- 
dwmw2


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

* Re: linux-next: firmware build failure
  2008-06-04  6:46 Stephen Rothwell
@ 2008-06-04  9:22 ` David Woodhouse
  2008-06-04 10:40   ` Stephen Rothwell
  2008-06-04  9:53 ` David Woodhouse
  1 sibling, 1 reply; 10+ messages in thread
From: David Woodhouse @ 2008-06-04  9:22 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next

On Wed, 2008-06-04 at 16:46 +1000, Stephen Rothwell wrote:
> -                 echo "    .align $(ASM_ALIGN)"                        >>$@;\
> +                 echo "    .p2align $${ASM_ALIGN}"                     >>$@;\

Ah, thanks. I did originally start doing it with big C files with char
arrays, which made this part easier -- but I really wanted to
use .incbin so I didn't have to copy the whole of the object into
'source' code. Just checking that that actually does the right thing on
ppc and ppc64 too, and I'll refactor it to include that. And the kaweth
fix.

Then I'll go seeking the usb tree of which you speak, with the ti patch
that conflicts. This not the tree at
kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6.git labelled 'junk
tree; please ignore', I assume?

-- 
dwmw2


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

* linux-next: firmware build failure
@ 2008-06-04  6:46 Stephen Rothwell
  2008-06-04  9:22 ` David Woodhouse
  2008-06-04  9:53 ` David Woodhouse
  0 siblings, 2 replies; 10+ messages in thread
From: Stephen Rothwell @ 2008-06-04  6:46 UTC (permalink / raw)
  To: David Woodhouse; +Cc: linux-next

Hi David,

Today's linux-next build (x86_64 allmodconfig) failed like this:

firmware/whiteheat_loader.fw.gen.S: Assembler messages:
firmware/whiteheat_loader.fw.gen.S:8: Error: alignment not a power of 2
firmware/whiteheat_loader.fw.gen.S:12: Error: alignment not a power of 2

This file looked like:
-------------------------------------------
/* Generated by firmware/Makefile */
    .section .rodata
    .align 
_fw_whiteheat_loader_fw_bin:
    .incbin "firmware/whiteheat_loader.fw"
_fw_end:
   .section .rodata.str,"aMS",@progbits,1
    .align 3
_fw_whiteheat_loader_fw_name:
    .string "whiteheat_loader.fw"
    .section .builtin_fw,"a",@progbits
    .align 3
    .quad _fw_whiteheat_loader_fw_name
    .quad _fw_whiteheat_loader_fw_bin
    .quad _fw_end - _fw_whiteheat_loader_fw_bin
------------------------------------------------

My gas manual says: "The way the required alignment is specified varies
from system to system."  So you should probably use .p2align instead (see
patch below.

Also:

drivers/net/usb/kaweth.c: In function 'kaweth_download_firmware':
drivers/net/usb/kaweth.c:422: error: 'data' undeclared (first use in this function)

Fixed by patch below (should be done better).
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

>From f0c5123415078e99c9b37d73afb9221dafcecd1d Mon Sep 17 00:00:00 2001
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Wed, 4 Jun 2008 16:44:11 +1000
Subject: [PATCH] firmware: build fixes 1

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 drivers/net/usb/kaweth.c |    2 ++
 firmware/Makefile        |    6 +++---
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/net/usb/kaweth.c b/drivers/net/usb/kaweth.c
index 156b61c..9b1da4b 100644
--- a/drivers/net/usb/kaweth.c
+++ b/drivers/net/usb/kaweth.c
@@ -419,9 +419,11 @@ static int kaweth_download_firmware(struct kaweth_device *kaweth,
 	dbg("High: %i, Low:%i", kaweth->firmware_buf[3],
 		   kaweth->firmware_buf[2]);
 
+#if 0
 	dbg("Downloading firmware at %p to kaweth device at %p",
 	    data,
 	    kaweth);
+#endif
 	dbg("Firmware length: %d", data_len);
 
 	return kaweth_control(kaweth,
diff --git a/firmware/Makefile b/firmware/Makefile
index 1d84237..d1e4675 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
@@ -61,16 +61,16 @@ quiet_cmd_fwbin = MK_FW   $@
 		  ASM_ALIGN=$(if $(CONFIG_64BIT),3,2);			     \
 		  echo "/* Generated by firmware/Makefile */"		> $@;\
 		  echo "    .section .rodata"				>>$@;\
-		  echo "    .align $(ASM_ALIGN)"			>>$@;\
+		  echo "    .p2align $${ASM_ALIGN}"			>>$@;\
 		  echo "_fw_$${FWSTR}_bin:"				>>$@;\
 		  echo "    .incbin \"$(2)\""				>>$@;\
 		  echo "_fw_end:"					>>$@;\
 		  echo "   .section .rodata.str,\"aMS\",@progbits,1"	>>$@;\
-		  echo "    .align $${ASM_ALIGN}"			>>$@;\
+		  echo "    .p2align $${ASM_ALIGN}"			>>$@;\
 		  echo "_fw_$${FWSTR}_name:"				>>$@;\
 		  echo "    .string \"$$FWNAME\""			>>$@;\
 		  echo "    .section .builtin_fw,\"a\",@progbits"	>>$@;\
-		  echo "    .align $${ASM_ALIGN}"			>>$@;\
+		  echo "    .p2align $${ASM_ALIGN}"			>>$@;\
 		  echo "    $${ASM_WORD} _fw_$${FWSTR}_name" 		>>$@;\
 		  echo "    $${ASM_WORD} _fw_$${FWSTR}_bin" 		>>$@;\
 		  echo "    $${ASM_WORD} _fw_end - _fw_$${FWSTR}_bin"	>>$@;
-- 
1.5.5.3


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

end of thread, other threads:[~2008-06-12  8:54 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-06  7:47 linux-next: firmware build failure Stephen Rothwell
2008-06-06  9:09 ` David Woodhouse
2008-06-06  9:31 ` David Woodhouse
  -- strict thread matches above, loose matches on Subject: below --
2008-06-12  6:28 Stephen Rothwell
2008-06-12  8:54 ` David Woodhouse
2008-06-04  6:46 Stephen Rothwell
2008-06-04  9:22 ` David Woodhouse
2008-06-04 10:40   ` Stephen Rothwell
2008-06-04  9:53 ` David Woodhouse
2008-06-04 10:47   ` Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).