2002-12-22 11:18:08

by Erik Andersen

[permalink] [raw]
Subject: [PATCH] fix 2.4.x ieee1394

On Tue Dec 17, 2002 at 04:14:22PM +0000, linux-kernel wrote:
> ChangeSet 1.901, 2002/12/17 14:14:22-02:00, [email protected]
>
> [PATCH] Linux1394 Firewire
>
> Syncs to our Linux-2.4 branch. Mostly bug fixes. I'll start sending more
> frequent and mmore verbose patches.
>
>
> # This patch includes the following deltas:
> # ChangeSet 1.900 -> 1.901
[-------------snip---------]
> diff -Nru a/drivers/ieee1394/Makefile b/drivers/ieee1394/Makefile
> --- a/drivers/ieee1394/Makefile Tue Dec 17 12:33:07 2002
> +++ b/drivers/ieee1394/Makefile Tue Dec 17 12:33:07 2002
> @@ -2,11 +2,8 @@
> # Makefile for the Linux IEEE 1394 implementation
> #
>
> -O_TARGET := ieee1394drv.o
> -

After this change, firewire doesn't build for me when adding
1394 stuff directly into the kernel, i.e.

CONFIG_IEEE1394=y
CONFIG_IEEE1394_OHCI1394=m
CONFIG_IEEE1394_SBP2=m
CONFIG_IEEE1394_RAWIO=y

The top level kernel Makefile has:
DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
but there is no longer a ieee1394drv.o target. This patch fixes
the problem.

--- linux/Makefile.orig 2002-12-21 14:32:42.000000000 -0700
+++ linux/Makefile 2002-12-21 19:59:00.000000000 -0700
@@ -153,7 +153,7 @@
DRIVERS-$(CONFIG_FC4) += drivers/fc4/fc4.a
DRIVERS-$(CONFIG_SCSI) += drivers/scsi/scsidrv.o
DRIVERS-$(CONFIG_FUSION_BOOT) += drivers/message/fusion/fusion.o
-DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
+DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394.o

ifneq ($(CONFIG_CD_NO_IDESCSI)$(CONFIG_BLK_DEV_IDECD)$(CONFIG_BLK_DEV_SR)$(CONFIG_PARIDE_PCD),)
DRIVERS-y += drivers/cdrom/driver.o

-Erik

--
Erik B. Andersen http://codepoet-consulting.com/
--This message was written using 73% post-consumer electrons--


2002-12-22 13:53:50

by Ben Collins

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

>
> After this change, firewire doesn't build for me when adding
> 1394 stuff directly into the kernel, i.e.
>
> CONFIG_IEEE1394=y
> CONFIG_IEEE1394_OHCI1394=m
> CONFIG_IEEE1394_SBP2=m
> CONFIG_IEEE1394_RAWIO=y
>
> The top level kernel Makefile has:
> DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
> but there is no longer a ieee1394drv.o target. This patch fixes
> the problem.

Thanks Erik. I like this fix better than adding the cruft back into the
ieee1394 Makefile.

--
Debian - http://www.debian.org/
Linux 1394 - http://www.linux1394.org/
Subversion - http://subversion.tigris.org/
Deqo - http://www.deqo.com/

2002-12-29 15:30:06

by Adrian Bunk

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

On Sun, Dec 22, 2002 at 04:26:13AM -0700, Erik Andersen wrote:
> On Tue Dec 17, 2002 at 04:14:22PM +0000, linux-kernel wrote:
>...
> > --- a/drivers/ieee1394/Makefile Tue Dec 17 12:33:07 2002
> > +++ b/drivers/ieee1394/Makefile Tue Dec 17 12:33:07 2002
> > @@ -2,11 +2,8 @@
> > # Makefile for the Linux IEEE 1394 implementation
> > #
> >
> > -O_TARGET := ieee1394drv.o
> > -
>
> After this change, firewire doesn't build for me when adding
> 1394 stuff directly into the kernel, i.e.
>
> CONFIG_IEEE1394=y
> CONFIG_IEEE1394_OHCI1394=m
> CONFIG_IEEE1394_SBP2=m
> CONFIG_IEEE1394_RAWIO=y
>
> The top level kernel Makefile has:
> DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
> but there is no longer a ieee1394drv.o target. This patch fixes
> the problem.
>...

When I try 2.4.21-pre2 with your patch and the IEEE 1394 options you
mention in your mail _nothing_ gets built inside the drivers/ieee1394
directory and the error message at the final linking is:

<-- snip -->

...
-o vmlinux
ld: cannot open drivers/ieee1394/ieee1394.o: No such file or directory
make: *** [vmlinux] Error 1

<-- snip -->


How did you manage to get a kernel that actually compiles?


> -Erik

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed

2002-12-29 16:35:50

by Erik Andersen

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

On Sun Dec 29, 2002 at 04:38:21PM +0100, Adrian Bunk wrote:
> When I try 2.4.21-pre2 with your patch and the IEEE 1394 options you
> mention in your mail _nothing_ gets built inside the drivers/ieee1394
> directory and the error message at the final linking is:
>
> <-- snip -->
>
> ...
> -o vmlinux
> ld: cannot open drivers/ieee1394/ieee1394.o: No such file or directory
> make: *** [vmlinux] Error 1
>
> <-- snip -->
>
>
> How did you manage to get a kernel that actually compiles?
>

Sorry about that. I missed a spot. Here is the full fix:

--- linux/drivers/ieee1394/Makefile.orig 2002-12-21 14:32:36.000000000 -0700
+++ linux/drivers/ieee1394/Makefile 2002-12-21 19:43:05.000000000 -0700
@@ -18,7 +18,8 @@
obj-$(CONFIG_IEEE1394_AMDTP) += amdtp.o
obj-$(CONFIG_IEEE1394_CMP) += cmp.o

-include $(TOPDIR)/Rules.make
-
ieee1394.o: $(ieee1394-objs)
$(LD) $(LDFLAGS) -r -o $@ $(ieee1394-objs)
+
+include $(TOPDIR)/Rules.make
+
--- linux/Makefile.orig 2002-12-21 14:32:42.000000000 -0700
+++ linux/Makefile 2002-12-21 19:59:00.000000000 -0700
@@ -153,7 +153,7 @@
DRIVERS-$(CONFIG_FC4) += drivers/fc4/fc4.a
DRIVERS-$(CONFIG_SCSI) += drivers/scsi/scsidrv.o
DRIVERS-$(CONFIG_FUSION_BOOT) += drivers/message/fusion/fusion.o
-DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
+DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394.o

ifneq ($(CONFIG_CD_NO_IDESCSI)$(CONFIG_BLK_DEV_IDECD)$(CONFIG_BLK_DEV_SR)$(CONFIG_PARIDE_PCD),)
DRIVERS-y += drivers/cdrom/driver.o

-Erik

--
Erik B. Andersen http://codepoet-consulting.com/
--This message was written using 73% post-consumer electrons--

2002-12-29 16:47:55

by Ben Collins

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

> Sorry about that. I missed a spot. Here is the full fix:
>

Thanks. I commited my portion.

--
Debian - http://www.debian.org/
Linux 1394 - http://www.linux1394.org/
Subversion - http://subversion.tigris.org/
Deqo - http://www.deqo.com/

2002-12-29 17:35:37

by Adrian Bunk

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

On Sun, Dec 29, 2002 at 09:44:09AM -0700, Erik Andersen wrote:
> On Sun Dec 29, 2002 at 04:38:21PM +0100, Adrian Bunk wrote:
> > When I try 2.4.21-pre2 with your patch and the IEEE 1394 options you
> > mention in your mail _nothing_ gets built inside the drivers/ieee1394
> > directory and the error message at the final linking is:
> >
> > <-- snip -->
> >
> > ...
> > -o vmlinux
> > ld: cannot open drivers/ieee1394/ieee1394.o: No such file or directory
> > make: *** [vmlinux] Error 1
> >
> > <-- snip -->
> >
> >
> > How did you manage to get a kernel that actually compiles?
> >
>
> Sorry about that. I missed a spot. Here is the full fix:
>...

Thanks, I can confirm that this patch fixes it.

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed

2002-12-31 15:12:15

by Kai Germaschewski

[permalink] [raw]
Subject: Re: [PATCH] fix 2.4.x ieee1394

On Sun, 29 Dec 2002, Ben Collins wrote:

> > Sorry about that. I missed a spot. Here is the full fix:
> >
>
> Thanks. I commited my portion.

I don't consider myself in charge for 2.4 kbuild, but I'm pretty sure all
of these fixes are wrong, they won't work when more than just the core
(ieee1394.o) is built-in. Reverting to the old Makefile seems the easiest
and obvious fix.

--Kai