[parisc-linux-cvs] 2.6.0-test5-pa0 cleanups
Grant Grundler
grundler@parisc-linux.org
Wed, 10 Sep 2003 23:07:10 -0600
Here are some minor cleanups that I'm not sure I should
be committing or not. willy let me know which bits I should
commit. Summary of changes by file:
arch/parisc/Kconfig
Disable HPUX for 64-bit since it doesn't compile
since I modified it to use STREG/LDREG.
drivers/serial/Kconfig
CONFIG_PDC_CONSOLE depends on CONFIG_VT in order
to pick up console_driver global.
include/asm-parisc/bitops.h
add comments to __ffs()
net/ipv4/ip_fragment.c
fix warning. atomic_sub() takes int for the first parameter.
"- sizeof()" is a long negative constant. Perhaps it's a
gcc 3.0.4 (hppa64) compiler bug that it doesn't get reduced to int.
No warnings for atomic_add(sizeof(foo),xxx) suggest it's normally ok.
grant
Index: arch/parisc/Kconfig
===================================================================
RCS file: /var/cvs/linux-2.6/arch/parisc/Kconfig,v
retrieving revision 1.8
diff -u -p -r1.8 Kconfig
--- arch/parisc/Kconfig 8 Sep 2003 22:00:21 -0000 1.8
+++ arch/parisc/Kconfig 11 Sep 2003 04:34:51 -0000
@@ -150,6 +150,7 @@ config COMPAT
config HPUX
bool "Support for HP-UX binaries"
+ depends on !PARISC64
config NR_CPUS
int "Maximum number of CPUs (2-32)"
Index: drivers/serial/Kconfig
===================================================================
RCS file: /var/cvs/linux-2.6/drivers/serial/Kconfig,v
retrieving revision 1.4
diff -u -p -r1.4 Kconfig
--- drivers/serial/Kconfig 8 Sep 2003 21:42:22 -0000 1.4
+++ drivers/serial/Kconfig 11 Sep 2003 04:34:51 -0000
@@ -373,13 +373,14 @@ config SERIAL_MUX_CONSOLE
config PDC_CONSOLE
bool "PDC software console support"
- depends on PARISC && !SERIAL_MUX
+ depends on PARISC && !SERIAL_MUX && VT
default n
help
Saying Y here will enable the software based PDC console to be
used as the system console. This is useful for machines in
- which the hardware based console has not been written yet. The
- following steps must be competed to use the PDC console:
+ which the hardware based console has not been written yet or to
+ enable console output before regular console device has started.
+ The following steps must be competed to use the PDC console:
1. create the device entry (mknod /dev/ttyB0 c 11 0)
2. Edit the /etc/inittab to start a getty listening on /dev/ttyB0
Index: include/asm-parisc/bitops.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/asm-parisc/bitops.h,v
retrieving revision 1.6
diff -u -p -r1.6 bitops.h
--- include/asm-parisc/bitops.h 8 Sep 2003 22:00:28 -0000 1.6
+++ include/asm-parisc/bitops.h 11 Sep 2003 04:34:52 -0000
@@ -232,24 +232,24 @@ static __inline__ unsigned long __ffs(un
#if BITS_PER_LONG > 32
" ldi 63,%1\n"
" extrd,u,*<> %0,63,32,%%r0\n"
- " extrd,u,*TR %0,31,32,%0\n"
+ " extrd,u,*TR %0,31,32,%0\n" /* move top 32-bits down */
" addi -32,%1,%1\n"
#else
" ldi 31,%1\n"
#endif
" extru,<> %0,31,16,%%r0\n"
- " extru,TR %0,15,16,%0\n"
+ " extru,TR %0,15,16,%0\n" /* xxxx0000 -> 0000xxxx */
" addi -16,%1,%1\n"
" extru,<> %0,31,8,%%r0\n"
- " extru,TR %0,23,8,%0\n"
+ " extru,TR %0,23,8,%0\n" /* 0000xx00 -> 000000xx */
" addi -8,%1,%1\n"
" extru,<> %0,31,4,%%r0\n"
- " extru,TR %0,27,4,%0\n"
+ " extru,TR %0,27,4,%0\n" /* 000000x0 -> 0000000x */
" addi -4,%1,%1\n"
" extru,<> %0,31,2,%%r0\n"
- " extru,TR %0,29,2,%0\n"
+ " extru,TR %0,29,2,%0\n" /* 0000000y, 1100b -> 0011b */
" addi -2,%1,%1\n"
- " extru,= %0,31,1,%%r0\n"
+ " extru,= %0,31,1,%%r0\n" /* check last bit */
" addi -1,%1,%1\n"
: "+r" (x), "=r" (ret) );
return ret;
@@ -291,7 +291,7 @@ static __inline__ int fls(int x)
" zdep,TR %0,27,28,%0\n" /* x0000000 */
" addi 4,%1,%1\n"
" extru,<> %0,1,2,%%r0\n"
- " zdep,TR %0,29,30,%0\n" /* y0000000 (y&3 = 0 */
+ " zdep,TR %0,29,30,%0\n" /* y0000000 (y&3) = 0 */
" addi 2,%1,%1\n"
" extru,= %0,0,1,%%r0\n"
" addi 1,%1,%1\n" /* if y & 8, add 1 */
Index: net/ipv4/ip_fragment.c
===================================================================
RCS file: /var/cvs/linux-2.6/net/ipv4/ip_fragment.c,v
retrieving revision 1.1
diff -u -p -r1.1 ip_fragment.c
--- net/ipv4/ip_fragment.c 29 Jul 2003 17:02:22 -0000 1.1
+++ net/ipv4/ip_fragment.c 11 Sep 2003 04:34:52 -0000
@@ -176,7 +176,7 @@ static __inline__ void frag_kfree_skb(st
static __inline__ void frag_free_queue(struct ipq *qp)
{
- atomic_sub(sizeof(struct ipq), &ip_frag_mem);
+ atomic_sub((int)sizeof(struct ipq), &ip_frag_mem);
kfree(qp);
}