linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: Linux 2.5.40-ac1
@ 2002-10-03 14:45 Manfred Spraul
  2002-10-03 14:50 ` David S. Miller
  2002-10-03 15:17 ` Alan Cox
  0 siblings, 2 replies; 19+ messages in thread
From: Manfred Spraul @ 2002-10-03 14:45 UTC (permalink / raw)
  To: Alan Cox; +Cc: linux-kernel

 > o	Fix abuse of set_bit in winbond-840		(me)

Were there bug reports, Have you tested the change?

I think the cpu_to_le32 is wrong.

On big endian computers, the nic is set into a big-endian mode, and it 
did work with set_bit on my power mac. Unfortunately, I don't have 
access to it right now.

--
	Manfred





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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:45 Linux 2.5.40-ac1 Manfred Spraul
@ 2002-10-03 14:50 ` David S. Miller
  2002-10-03 15:18   ` Manfred Spraul
  2002-10-03 15:17 ` Alan Cox
  1 sibling, 1 reply; 19+ messages in thread
From: David S. Miller @ 2002-10-03 14:50 UTC (permalink / raw)
  To: manfred; +Cc: alan, linux-kernel

   From: Manfred Spraul <manfred@colorfullife.com>
   Date: Thu, 03 Oct 2002 16:45:59 +0200

   On big endian computers, the nic is set into a big-endian mode, and it 
   did work with set_bit on my power mac. Unfortunately, I don't have 
   access to it right now.
   
How about a 64-bit system where set_bit works on 64-bit longs
and not 32-bit ones?  That is why the current code there is broken.

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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:18   ` Manfred Spraul
@ 2002-10-03 15:15     ` David S. Miller
  2002-10-03 15:48     ` Alan Cox
  1 sibling, 0 replies; 19+ messages in thread
From: David S. Miller @ 2002-10-03 15:15 UTC (permalink / raw)
  To: manfred; +Cc: alan, linux-kernel

   From: Manfred Spraul <manfred@colorfullife.com>
   Date: Thu, 03 Oct 2002 17:18:06 +0200
   
   Patch again attached, but untested.

I'm fine with it, just make sure it doesn't give Linus heart burn :-)

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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:45 Linux 2.5.40-ac1 Manfred Spraul
  2002-10-03 14:50 ` David S. Miller
@ 2002-10-03 15:17 ` Alan Cox
  2002-10-03 15:34   ` Manfred Spraul
  1 sibling, 1 reply; 19+ messages in thread
From: Alan Cox @ 2002-10-03 15:17 UTC (permalink / raw)
  To: Manfred Spraul; +Cc: Alan Cox, Linux Kernel Mailing List

On Thu, 2002-10-03 at 15:45, Manfred Spraul wrote:
>  > o	Fix abuse of set_bit in winbond-840		(me)
> 
> Were there bug reports, Have you tested the change?

Yes and no - I don't have an 840

> I think the cpu_to_le32 is wrong.
> 
> On big endian computers, the nic is set into a big-endian mode, and it 
> did work with set_bit on my power mac. Unfortunately, I don't have 
> access to it right now.

The checks I did were that it seemed to produce the same data in both
cases. So if it was wrong before (using set_bit) its probably wrong now.


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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:50 ` David S. Miller
@ 2002-10-03 15:18   ` Manfred Spraul
  2002-10-03 15:15     ` David S. Miller
  2002-10-03 15:48     ` Alan Cox
  0 siblings, 2 replies; 19+ messages in thread
From: Manfred Spraul @ 2002-10-03 15:18 UTC (permalink / raw)
  To: David S. Miller; +Cc: alan, linux-kernel

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

David S. Miller wrote:
>    
> How about a 64-bit system where set_bit works on 64-bit longs
> and not 32-bit ones?  That is why the current code there is broken.
 >

There should bit nonatomic bit ops for every byte width.

http://marc.theaimsgroup.com/?l=linux-kernel&m=99167415926343&w=2

I even sent you the patch proposal, but never got a reply.

Patch again attached, but untested.
--
	Manfred

[-- Attachment #2: patch-bitops --]
[-- Type: text/plain, Size: 620 bytes --]

--- 2.4/include/linux/bitops.h	Sat Apr 28 00:48:19 2001
+++ build-2.4/include/linux/bitops.h	Tue Jun  5 19:40:43 2001
@@ -68,5 +68,27 @@
 
 #include <asm/bitops.h>
 
+#ifdef __KERNEL__
+#include <linux/types.h>
+#define BUILD_SET_BIT(n) \
+static inline void __set_bit_##n(int offset, u##n *data) \
+{ \
+	data[offset/n] |= (1 << (offset%n)); \
+}
+
+#ifndef _HAVE_ARCH_SET_BIT_8
+BUILD_SET_BIT(8)
+#endif
+#ifndef _HAVE_ARCH_SET_BIT_16
+BUILD_SET_BIT(16)
+#endif
+#ifndef _HAVE_ARCH_SET_BIT_32
+BUILD_SET_BIT(32)
+#endif
+#ifndef _HAVE_ARCH_SET_BIT_64
+BUILD_SET_BIT(64)
+#endif
+#undef BUILD_SET_BIT
+#endif
 
 #endif

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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:17 ` Alan Cox
@ 2002-10-03 15:34   ` Manfred Spraul
  0 siblings, 0 replies; 19+ messages in thread
From: Manfred Spraul @ 2002-10-03 15:34 UTC (permalink / raw)
  To: Alan Cox; +Cc: Linux Kernel Mailing List

Alan Cox wrote:
> 
> The checks I did were that it seemed to produce the same data in both
> cases. So if it was wrong before (using set_bit) its probably wrong now.
 >
Which arch?
On ppc, __set_bit() stores in big endian format, i.e. the cpu_to_le32 
would be wrong
I try to figure out what set_bit() does.

--
	Manfred


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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:18   ` Manfred Spraul
  2002-10-03 15:15     ` David S. Miller
@ 2002-10-03 15:48     ` Alan Cox
  2002-10-03 15:53       ` Manfred Spraul
  1 sibling, 1 reply; 19+ messages in thread
From: Alan Cox @ 2002-10-03 15:48 UTC (permalink / raw)
  To: Manfred Spraul; +Cc: David S. Miller, alan, Linux Kernel Mailing List

On Thu, 2002-10-03 at 16:18, Manfred Spraul wrote:
> There should bit nonatomic bit ops for every byte width.
> 
> http://marc.theaimsgroup.com/?l=linux-kernel&m=99167415926343&w=2
> 
> I even sent you the patch proposal, but never got a reply.
> 
> Patch again attached, but untested.

What about reverse endianness ?

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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:48     ` Alan Cox
@ 2002-10-03 15:53       ` Manfred Spraul
  0 siblings, 0 replies; 19+ messages in thread
From: Manfred Spraul @ 2002-10-03 15:53 UTC (permalink / raw)
  To: Alan Cox; +Cc: David S. Miller, alan, Linux Kernel Mailing List

Alan Cox wrote:
> On Thu, 2002-10-03 at 16:18, Manfred Spraul wrote:
> 
>>There should bit nonatomic bit ops for every byte width.
>>
>>http://marc.theaimsgroup.com/?l=linux-kernel&m=99167415926343&w=2
>>
>>I even sent you the patch proposal, but never got a reply.
>>
>>Patch again attached, but untested.
> 
> 
> What about reverse endianness ?

AFAIK, writeX macros should swap as needed, i.e.

	writel(0x100,ioaddr);

should arrive as bit 8 set on the hardware. [please correct me if I'm 
wrong] Thus the input into write{b,w,l} should be in host byte order.

	u{8,16,32}	array[];

	__set_bit_{8,16,32}(,array);

	write{b,w,l}(array[],ioaddr);

would achieve that.


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

* Re: Linux 2.5.40-ac1
  2002-10-03 23:44         ` Greg Ungerer
@ 2002-10-04  0:32           ` Rik van Riel
  0 siblings, 0 replies; 19+ messages in thread
From: Rik van Riel @ 2002-10-04  0:32 UTC (permalink / raw)
  To: Greg Ungerer; +Cc: Christoph Hellwig, Alan Cox, linux-kernel

On Fri, 4 Oct 2002, Greg Ungerer wrote:
> Rik van Riel wrote:

> Easy done. Would it bother anyone having a few files
> named XYZ-nommu.c in there?

Excellent.

> Although the sticking point may be the common files that
> still contain a lot of ifdefs.

That's ok initially. We can probably split up functions
somewhat or do other tricks to reduce the number of
ifdefs later on.

Alternatively, we could do the splitting first and the
nommu merge later. I don't really care about the order
as long as things don't happen simultaneously in patch
that's too big to check ;)

regards,

Rik
-- 
Bravely reimplemented by the knights who say "NIH".

http://www.surriel.com/		http://distro.conectiva.com/

Spamtraps of the month:  september@surriel.com trac@trac.org


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

* Re: Linux 2.5.40-ac1
  2002-10-03 19:16       ` Rik van Riel
@ 2002-10-03 23:44         ` Greg Ungerer
  2002-10-04  0:32           ` Rik van Riel
  0 siblings, 1 reply; 19+ messages in thread
From: Greg Ungerer @ 2002-10-03 23:44 UTC (permalink / raw)
  To: Rik van Riel; +Cc: Christoph Hellwig, Alan Cox, linux-kernel

Hi Rik,

Rik van Riel wrote:
> On Thu, 3 Oct 2002, Christoph Hellwig wrote:
> 
>>On Thu, Oct 03, 2002 at 10:20:03AM -0400, Alan Cox wrote:
> 
> 
>>>The two are so different I think that keeping it seperate is actually the
>>>right idea personally.
>>
>>Did you actually take a look?  Many files are basically the same and other
>>are just totally stubbed out in nommu.
> 
> 
> So how about having one mm/ directory with:
> 
> 1) the common stuff
> 2) the MMU stuff
> 3) the NOMMU stuff
> 
> ... and some magic in Makefile to select which .c files to
> compile ?
> 
> That should keep code duplication to a minimum.

Easy done. Would it bother anyone having a few files
named XYZ-nommu.c in there?

Although the sticking point may be the common files that
still contain a lot of ifdefs.

Regards
Greg



------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Wizard        EMAIL:  gerg@snapgear.com
SnapGear Pty Ltd                               PHONE:    +61 7 3435 2888
825 Stanley St,                                  FAX:    +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia              WEB:   www.SnapGear.com


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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:51     ` Christoph Hellwig
  2002-10-03 15:25       ` Alan Cox
@ 2002-10-03 19:16       ` Rik van Riel
  2002-10-03 23:44         ` Greg Ungerer
  1 sibling, 1 reply; 19+ messages in thread
From: Rik van Riel @ 2002-10-03 19:16 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: Alan Cox, Greg Ungerer, linux-kernel

On Thu, 3 Oct 2002, Christoph Hellwig wrote:
> On Thu, Oct 03, 2002 at 10:20:03AM -0400, Alan Cox wrote:

> > The two are so different I think that keeping it seperate is actually the
> > right idea personally.
>
> Did you actually take a look?  Many files are basically the same and other
> are just totally stubbed out in nommu.

So how about having one mm/ directory with:

1) the common stuff
2) the MMU stuff
3) the NOMMU stuff

... and some magic in Makefile to select which .c files to
compile ?

That should keep code duplication to a minimum.

regards,

Rik
-- 
A: No.
Q: Should I include quotations after my reply?

http://www.surriel.com/		http://distro.conectiva.com/


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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:25       ` Alan Cox
  2002-10-03 15:28         ` Christoph Hellwig
@ 2002-10-03 15:31         ` Greg Ungerer
  1 sibling, 0 replies; 19+ messages in thread
From: Greg Ungerer @ 2002-10-03 15:31 UTC (permalink / raw)
  To: Alan Cox; +Cc: Christoph Hellwig, Alan Cox, Linux Kernel Mailing List

Alan Cox wrote:
> On Thu, 2002-10-03 at 15:51, Christoph Hellwig wrote:
> 
>>Did you actually take a look?  Many files are basically the same and other
>>are just totally stubbed out in nommu.
> 
> 
> Basically but never entirely - if you can see a way to clean that up
> nicely that Linus would accept other than mmnommu then thats even
> better. I couldnt see a way of getting enough ifdefs out of the tree

And this really is the problem. There is a lot of ifdefs, lots
of little differences. I am not sure how exactly we could
clean this up.

Regards
Greg



------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Wizard        EMAIL:  gerg@snapgear.com
Snapgear Pty Ltd                               PHONE:    +61 7 3279 1822
825 Stanley St,                                  FAX:    +61 7 3279 1820
Woolloongabba, QLD, 4102, Australia              WEB:   www.SnapGear.com


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

* Re: Linux 2.5.40-ac1
  2002-10-03 15:25       ` Alan Cox
@ 2002-10-03 15:28         ` Christoph Hellwig
  2002-10-03 15:31         ` Greg Ungerer
  1 sibling, 0 replies; 19+ messages in thread
From: Christoph Hellwig @ 2002-10-03 15:28 UTC (permalink / raw)
  To: Alan Cox; +Cc: Alan Cox, Greg Ungerer, Linux Kernel Mailing List

On Thu, Oct 03, 2002 at 04:25:38PM +0100, Alan Cox wrote:
> On Thu, 2002-10-03 at 15:51, Christoph Hellwig wrote:
> > Did you actually take a look?  Many files are basically the same and other
> > are just totally stubbed out in nommu.
> 
> Basically but never entirely - if you can see a way to clean that up
> nicely that Linus would accept other than mmnommu then thats even
> better. I couldnt see a way of getting enough ifdefs out of the tree

I'll start feeding patches once I'm back from a small journey


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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:51     ` Christoph Hellwig
@ 2002-10-03 15:25       ` Alan Cox
  2002-10-03 15:28         ` Christoph Hellwig
  2002-10-03 15:31         ` Greg Ungerer
  2002-10-03 19:16       ` Rik van Riel
  1 sibling, 2 replies; 19+ messages in thread
From: Alan Cox @ 2002-10-03 15:25 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: Alan Cox, Greg Ungerer, Linux Kernel Mailing List

On Thu, 2002-10-03 at 15:51, Christoph Hellwig wrote:
> Did you actually take a look?  Many files are basically the same and other
> are just totally stubbed out in nommu.

Basically but never entirely - if you can see a way to clean that up
nicely that Linus would accept other than mmnommu then thats even
better. I couldnt see a way of getting enough ifdefs out of the tree


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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:20   ` Alan Cox
@ 2002-10-03 14:51     ` Christoph Hellwig
  2002-10-03 15:25       ` Alan Cox
  2002-10-03 19:16       ` Rik van Riel
  0 siblings, 2 replies; 19+ messages in thread
From: Christoph Hellwig @ 2002-10-03 14:51 UTC (permalink / raw)
  To: Alan Cox; +Cc: Christoph Hellwig, Greg Ungerer, linux-kernel

On Thu, Oct 03, 2002 at 10:20:03AM -0400, Alan Cox wrote:
> > The sepearate one is horrible maintaince wise.  Please introduce
> > CONFIG_MMU and try to make as many _files_ in mm/ conditional on
> > those.  Else use the proper ways (cond_syscall(), inline stubs) to
> > hide the differences.
> 
> The two are so different I think that keeping it seperate is actually the
> right idea personally.

Did you actually take a look?  Many files are basically the same and other
are just totally stubbed out in nommu.


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

* Re: Linux 2.5.40-ac1
  2002-10-03 14:17 ` Christoph Hellwig
@ 2002-10-03 14:20   ` Alan Cox
  2002-10-03 14:51     ` Christoph Hellwig
  0 siblings, 1 reply; 19+ messages in thread
From: Alan Cox @ 2002-10-03 14:20 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: Greg Ungerer, linux-kernel, Alan Cox

> The sepearate one is horrible maintaince wise.  Please introduce
> CONFIG_MMU and try to make as many _files_ in mm/ conditional on
> those.  Else use the proper ways (cond_syscall(), inline stubs) to
> hide the differences.

The two are so different I think that keeping it seperate is actually the
right idea personally. It will be up to the nommu people to chase the "real
computer" mmu code but I don't think that is a problem.

Some of the other areas you really do want to just hide the differences
nicely - eg in proc


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

* Re: Linux 2.5.40-ac1
  2002-10-02 23:38 Greg Ungerer
@ 2002-10-03 14:17 ` Christoph Hellwig
  2002-10-03 14:20   ` Alan Cox
  0 siblings, 1 reply; 19+ messages in thread
From: Christoph Hellwig @ 2002-10-03 14:17 UTC (permalink / raw)
  To: Greg Ungerer; +Cc: linux-kernel, Alan Cox

On Thu, Oct 03, 2002 at 09:38:11AM +1000, Greg Ungerer wrote:
> What do you think about the separate mm/mmnommu directories
> at the top level?  Should the mmnommu be merged into mm?

The sepearate one is horrible maintaince wise.  Please introduce
CONFIG_MMU and try to make as many _files_ in mm/ conditional on
those.  Else use the proper ways (cond_syscall(), inline stubs) to
hide the differences.



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

* Re: Linux 2.5.40-ac1
@ 2002-10-02 23:38 Greg Ungerer
  2002-10-03 14:17 ` Christoph Hellwig
  0 siblings, 1 reply; 19+ messages in thread
From: Greg Ungerer @ 2002-10-02 23:38 UTC (permalink / raw)
  To: linux-kernel; +Cc: Alan Cox


Hi Alan,

> Linux 2.5.40-ac1
[snip]
> o	Merge most of ucLinux stuff			(Greg Ungerer)

Woohoo!


> 	| It needs putting somewhere so we can pick over the
> 	| hard bits left
> 	| Q: Wouldn't drivers/char/mem-nommu.c be better

OK, that is easy to do...


> 	| Q: How to do the procfs stuff tidily

Yes. I need to spend some time on this one. Just lots
of little differences...


> 	| Q: Wouldn't it be nicer to move all mm or mmnommu specific ksyms
> 	|    int the relevant mm/*.c file area instead of kernel/ksyms

OK, I have a new patch today that cleans all this up.
I made all the existing ksysms symbols present. It turns out
many where already there in my more recent patches anyway.
A couple needed to be stubbed. The next patch has no diffs
to ksyms at all.


> 	| Q: Why ifdef out overcommit -  its even easier to account on 
> 	|    MMUless and useful info

I was looking over this yesterday too. Should be able to clean this
up a bit.

What do you think about the separate mm/mmnommu directories
at the top level?  Should the mmnommu be merged into mm?

Do you want me to CC you when I put new patches up?

Thanks
Greg


------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Wizard        EMAIL:  gerg@snapgear.com
SnapGear Pty Ltd                               PHONE:    +61 7 3435 2888
825 Stanley St,                                  FAX:    +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia              WEB:   www.SnapGear.com


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

* Linux 2.5.40-ac1
@ 2002-10-02 22:18 Alan Cox
  0 siblings, 0 replies; 19+ messages in thread
From: Alan Cox @ 2002-10-02 22:18 UTC (permalink / raw)
  To: linux-kernel



Linux 2.5.40-ac1

+	Initial port of aacraid driver to 2.5		(me)
+	vfat corruption fix				(Petr Vandrovec)
+	Clean up firestream warnings			(Francois Romieu)
+	Voyager support					(James Bottomley)
+	Fix split_vma					(Hugh Dickins)
+	Fix config in video subdirectory		(John Levon)
+	Update olympic driver to 2.5			(Mike Phillips)
+	Fix sg init error				(Mike Anderson)
+	Fix Rules.make
o	Merge most of ucLinux stuff			(Greg Ungerer)
	| It needs putting somewhere so we can pick over the
	| hard bits left
	| Q: Wouldn't drivers/char/mem-nommu.c be better
	| Q: How to do the procfs stuff tidily
	| Q: Wouldn't it be nicer to move all mm or mmnommu specific ksyms
	|    int the relevant mm/*.c file area instead of kernel/ksyms
	| Q: Why ifdef out overcommit -  its even easier to account on 
	|    MMUless and useful info
+	Stick tulip back under 10/100 ethernet		(me)
+	Correct docs for IBM touchpad back to how	(me)
	they were before
o	Fix abuse of set_bit in winbond-840		(me)
+	Fix abuse of set_bit in atp			(me)

--
	"When Dilbert has a better working environment than you
			its time to leave"
				- Anonymous

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

end of thread, other threads:[~2002-10-04  0:27 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-03 14:45 Linux 2.5.40-ac1 Manfred Spraul
2002-10-03 14:50 ` David S. Miller
2002-10-03 15:18   ` Manfred Spraul
2002-10-03 15:15     ` David S. Miller
2002-10-03 15:48     ` Alan Cox
2002-10-03 15:53       ` Manfred Spraul
2002-10-03 15:17 ` Alan Cox
2002-10-03 15:34   ` Manfred Spraul
  -- strict thread matches above, loose matches on Subject: below --
2002-10-02 23:38 Greg Ungerer
2002-10-03 14:17 ` Christoph Hellwig
2002-10-03 14:20   ` Alan Cox
2002-10-03 14:51     ` Christoph Hellwig
2002-10-03 15:25       ` Alan Cox
2002-10-03 15:28         ` Christoph Hellwig
2002-10-03 15:31         ` Greg Ungerer
2002-10-03 19:16       ` Rik van Riel
2002-10-03 23:44         ` Greg Ungerer
2002-10-04  0:32           ` Rik van Riel
2002-10-02 22:18 Alan Cox

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).