2003-07-09 05:20:59

by Andrew Morton

[permalink] [raw]
Subject: 2.5.74-mm3


ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.5/2.5.74/2.5.74-mm3/


. More CPU scheduler tweaks from Con

. All the rest is new bugfixes. Twenty three in fact.




Changes since 2.5.74-mm2:


linus.patch

Latest bitkeeper tree

-netstat-oops-fix.patch
-task_cpu-cleanup.patch
-misc9.patch
-breadahead-tweaks.patch
-xattr-cleanup.patch
-xattr-sharing.patch
-xattr-just-replace.patch
-xattr-fine-grained-locking-prep.patch
-xattr-fine-grained-locking.patch
-ipconfig-display-boot-server.patch
-quota-autoloading.patch
-bsd-accounting-speedup.patch
-add_timer-fix.patch

Merged

-cpumask_t-1.patch
-gcc-bug-workaround.patch
-sparse-apic-fix.patch
-nuke-cpumask_arith.patch
-p4-clockmod-cpumask-fix.patch

Folded into cpumask_t-1.patch

+cpumask_t-s390-fix.patch
+kgdb-cpumask_t.patch
+cpumask_t-x86_64-fix.patch
+sparc64-cpumask_t-fix.patch

cpumask_t fixes

+div64-fix.patch

Fix the consolidated div64() code

+compat_sys_sched_getaffinity-return-fix.patch

return value fix.

+reiserfs-dirty-memory-fix.patch

Fix VFS lockup with reiserfs.

+reiserfs-64-bit-fix.patch

Make reiserfs work on 64-bit machines

+kmap-removal-1.patch

kmap->kmap_atomic

+kallsyms-defaults-to-on.patch

make CONFIG_KALLSYMS harder to turn off

+misc29.patch

misc fixes

-mmap-prefault.patch

Dropped - readaround rework made it ineffective

+knfsd-umask-fix.patch

Fix kNFSd file creation modes

+aio-fork-fix.patch
+aio_complete-barrier-fix.patch

AIO bugfixes

+aio-O_SYNC-fix.patch
+aio-readahead-rework.patch

More AIO work.

-sleepometer.patch
-time-goes-backwards.patch

Dropped - I wasn't using it.

-nbd-locking-fixes.patch
-nbd-ioctl-compat.patch
+nbd-remove-open-release.patch
+nbd-use-set_blocksize.patch

NBD work.

+ext3_sync_fs-fix.patch

ext3 correctness fix

-fnup-stats.patch

debug stuff. Dropped.

+o3int.patch

More CPU scheduler interactivity work.

+oom-kiler-fixes.patch

ry not to kill kernel threads

+synaptics-reset-fix.patch

Synaptics fix

+yenta_socket-init-fix.patch

Cardbus initialisation ordering fix

+devfs-oops-fix.patch
+devfs-deadlock-fix.patch

devfs fixes

+ext3-block-allocation-cleanup.patch

Untangle the block allocator

+epoll-multiple-fds.patch

eventpoll fix.






All 113 patches:


linus.patch

mm.patch
add -mmN to EXTRAVERSION

kgdb-ga.patch
kgdb stub for ia32 (George Anzinger's one)

kgdb-remove-cpu_callout_map.patch
kgdb: remove cpu_callout_map decls

kgdb-use-ggdb.patch

kgdb-ga-docco-fixes.patch
kgdb doc. edits/corrections

cpumask_t-1.patch
cpumask_t: allow more than BITS_PER_LONG CPUs

cpumask_t-s390-fix.patch
cpumask_t fix for s390

kgdb-cpumask_t.patch

cpumask_t-x86_64-fix.patch
Fix cpumask changes for x86_64

sparc64-cpumask_t-fix.patch
fix cpumask_t for sparc64

reslabify-pgds-and-pmds.patch
re-slabify i386 pgd's and pmd's

div64-fix.patch
Fix do_div() for all architectures

compat_sys_sched_getaffinity-return-fix.patch
fix return of compat_sys_sched_getaffinity

reiserfs-dirty-memory-fix.patch
reiserfs dirty memory accounting fix

reiserfs-64-bit-fix.patch
fix reiserfs for 64bit arches

seqcount-locking.patch
i_size atomic access: infrastructure

i_size-atomic-access.patch
i_size atomic access

config_spinline.patch
uninline spinlocks for profiling accuracy.

ppc64-pci-update.patch

ppc64-reloc_hide.patch

ppc64-semaphore-reimplementation.patch
ppc64: use the ia32 semaphore implementation

sym-do-160.patch
make the SYM driver do 160 MB/sec

x86_64-fixes.patch
x86_64 fixes

delay-ksoftirqd-fallback.patch
Try harded in IRQ context before falling back to ksoftirqd

ds-09-vicam-usercopy-fix.patch
vicam usercopy fix

fbdev-2.patch

buffer-debug.patch
buffer.c debugging

rcu-stats.patch
RCU statistics reporting

mtrr-hang-fix.patch
Fix mtrr-related hang

intel8x0-cleanup.patch
intel8x0 cleanups

bio-too-big-fix.patch
Fix raid "bio too big" failures

kmap-removal-1.patch
replace some kmap()s with kmap_atomic()

kallsyms-defaults-to-on.patch
make CONFIG_KALLSYMS default to "on"

misc29.patch
misc fixes

linux-isp-2.patch

linux-isp-2-fix-again.patch
lost feral fix

list_del-debug.patch
list_del debug check

airo-schedule-fix.patch
airo.c: don't sleep in atomic regions

print-build-options-on-oops.patch
print a few config options on oops

show_task-free-stack-fix.patch
show_task() fix and cleanup

put_task_struct-debug.patch

ia32-mknod64.patch
mknod64 for ia32

ext2-64-bit-special-inodes.patch
ext2: support for 64-bit device nodes

ext3-64-bit-special-inodes.patch
ext3: support for 64-bit device nodes

64-bit-dev_t-kdev_t.patch
64-bit dev_t and kdev_t

oops-dump-preceding-code.patch
i386 oops output: dump preceding code

lockmeter.patch

invalidate_mmap_range.patch
Interface to invalidate regions of mmaps

knfsd-umask-fix.patch
Set umask correctly for nfsd kernel threads

aio-fork-fix.patch
Bug fix in AIO initialization

aio_complete-barrier-fix.patch
Fix race condition between aio_complete and aio_read_evt

aio-mm-refcounting-fix.patch
fix /proc mm_struct refcounting bug

aio-01-retry.patch
AIO: Core retry infrastructure

io_submit_one-EINVAL-fix.patch
Fix aio process hang on EINVAL

aio-02-lockpage_wq.patch
AIO: Async page wait

aio-03-fs_read.patch
AIO: Filesystem aio read

aio-04-buffer_wq.patch
AIO: Async buffer wait

aio-05-fs_write.patch
AIO: Filesystem aio write

aio-05-fs_write-fix.patch

aio-06-bread_wq.patch
AIO: Async block read

aio-06-bread_wq-fix.patch

aio-07-ext2getblk_wq.patch
AIO: Async get block for ext2

O_SYNC-speedup-2.patch
speed up O_SYNC writes

aio-09-o_sync.patch
aio O_SYNC

aio-10-BUG-fix.patch
AIO: fix a BUG

aio-11-workqueue-flush.patch
AIO: flush workqueues before destroying ioctx'es

aio-12-readahead.patch
AIO: readahead fixes

aio-dio-no-readahead.patch
aio O_DIRECT no readahead

lock_buffer_wq-fix.patch
lock_buffer_wq fix

unuse_mm-locked.patch
AIO: hold the context lock across unuse_mm

aio-take-task_lock.patch
From: Suparna Bhattacharya <[email protected]>
Subject: Re: 2.5.72-mm1 - Under heavy testing with AIO,.. vmstat seems to blow the kernel

aio-O_SYNC-fix.patch
Unify o_sync changes for aio and regular writes

aio-readahead-rework.patch
Unified page range readahead for aio and regular reads

vfsmount_lock.patch
From: Maneesh Soni <[email protected]>
Subject: [patch 1/2] vfsmount_lock

sched-hot-balancing-fix.patch
fix for CPU scheduler load distribution

truncate-pagefault-race-fix.patch
Fix vmtruncate race and distributed filesystem race

truncate-pagefault-race-fix-fix.patch
Make sure truncate fix has no race

printk-oops-mangle-fix.patch
disentangle printk's whilst oopsing on SMP

20-odirect_enable.patch

21-odirect_cruft.patch

22-read_proc.patch

23-write_proc.patch

24-commit_proc.patch

25-odirect.patch

nfs-O_DIRECT-always-enabled.patch
Force CONFIG_NFS_DIRECTIO

aha152x-oops-fix.patch
aha152X oops fixes

nbd-cleanups.patch
NBD: cosmetic cleanups

nbd-enhanced-diagnostics.patch
nbd: enhanced diagnostics support

nbd-remove-blksize-bits.patch
nbd: remove unneeded blksize_bits field

nbd-kobject-oops-fix.patch
nbd: initialise the embedded kobject

nbd-paranioa-cleanups.patch
nbd: cleanup PARANOIA usage & code

nbd-docco-update.patch
NBD documentation update

nbd-remove-open-release.patch
nbd: remove unneeded nbd_open/nbd_release and refcnt

nbd-use-set_blocksize.patch
nbd: make nbd and block layer agree about device and block sizes

acpismp-fix.patch
ACPI_HT_ONLY acpismp=force

oomkill-if-free-swap.patch
Don't skip oomkilling if there's free swap

apci-nmi-watchdog-fix.patch
ACPI poweroff trigers the NMI watchdog

jbd-commit-tricks.patch
JBD: checkpointing optimisations

jbd-dont-account-blocks-twice.patch
JBD: transaction buffer accounting fix

ext3_sync_fs-fix.patch
sync_fs() fix

kjournald-PF_SYNCWRITE.patch

o1-interactivity.patch
CPU scheduler interactivity patch

o2int.patch
O2int 0307041440 for 2.5.74-mm1

o3int.patch
O3int interactivity for 2.5.74-mm2

highpmd.patch
highpmd

oom-kiler-fixes.patch
oom killer fixes

synaptics-reset-fix.patch
synaptics driver reset fix

yenta_socket-init-fix.patch
yenta-socket initialisation fix

devfs-oops-fix.patch
devfs oops fix

devfs-deadlock-fix.patch
devfs deadlock fix

ext3-block-allocation-cleanup.patch

epoll-multiple-fds.patch
epoll-per-fd fix ...




2003-07-09 08:59:32

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3

> -cpumask_t-1.patch
> -gcc-bug-workaround.patch
> -sparse-apic-fix.patch
> -nuke-cpumask_arith.patch
> -p4-clockmod-cpumask-fix.patch
>
> Folded into cpumask_t-1.patch

This gives following compile error when compiling the kernel with APM support
for UP:

arch/i386/kernel/apm.c: In function `apm_bios_call':
arch/i386/kernel/apm.c:600: error: incompatible types in assignment
arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
arch/i386/kernel/apm.c:643: error: incompatible types in assignment

The attached patch fixes this...

Best regards
Thomas Schlichter


Attachments:
(No filename) (576.00 B)
fix_up_apm.diff (1.30 kB)
Download all attachments

2003-07-09 09:04:00

by Andrew Morton

[permalink] [raw]
Subject: Re: 2.5.74-mm3

Thomas Schlichter <[email protected]> wrote:
>
> This gives following compile error when compiling the kernel with APM support
> for UP:
>
> arch/i386/kernel/apm.c: In function `apm_bios_call':
> arch/i386/kernel/apm.c:600: error: incompatible types in assignment
> arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
> arch/i386/kernel/apm.c:643: error: incompatible types in assignment
>
> The attached patch fixes this...

Seems complex. I just have this:


diff -puN arch/i386/kernel/apm.c~cpumask-apm-fix-2 arch/i386/kernel/apm.c
--- 25/arch/i386/kernel/apm.c~cpumask-apm-fix-2 2003-07-08 23:09:23.000000000 -0700
+++ 25-akpm/arch/i386/kernel/apm.c 2003-07-08 23:28:50.000000000 -0700
@@ -528,7 +528,7 @@ static inline void apm_restore_cpus(cpum
* No CPU lockdown needed on a uniprocessor
*/

-#define apm_save_cpus() 0
+#define apm_save_cpus() CPU_MASK_NONE
#define apm_restore_cpus(x) (void)(x)

#endif

_

2003-07-09 09:13:22

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Wed, Jul 09, 2003 at 04:24:33AM -0500, Matt Mackall wrote:
> -#define apm_save_cpus() 0
> +#define apm_save_cpus() (current->cpus_allowed)
> #define apm_restore_cpus(x) (void)(x)

It's trying to describe an empty set of cpus. This is denoted by
CPU_MASK_NONE in the cpumask_t bits.


-- wli

2003-07-09 09:10:00

by Matt Mackall

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Tue, Jul 08, 2003 at 10:35:48PM -0700, Andrew Morton wrote:
> Merged
>
> -cpumask_t-1.patch
> -gcc-bug-workaround.patch
> -sparse-apic-fix.patch
> -nuke-cpumask_arith.patch
> -p4-clockmod-cpumask-fix.patch
>
> Folded into cpumask_t-1.patch
>
> +cpumask_t-s390-fix.patch
> +kgdb-cpumask_t.patch
> +cpumask_t-x86_64-fix.patch
> +sparc64-cpumask_t-fix.patch
>
> cpumask_t fixes

UP APM has broken since -mm2, looks like something like this is
needed (compiles, untested):

diff -urN -x genksyms -x '*.ver' -x '.patch*' -x '*.orig' orig/arch/i386/kernel/apm.c patched/arch/i386/kernel/apm.c
--- orig/arch/i386/kernel/apm.c 2003-07-09 04:07:06.000000000 -0500
+++ patched/arch/i386/kernel/apm.c 2003-07-09 04:19:52.000000000 -0500
@@ -528,7 +528,7 @@
* No CPU lockdown needed on a uniprocessor
*/

-#define apm_save_cpus() 0
+#define apm_save_cpus() (current->cpus_allowed)
#define apm_restore_cpus(x) (void)(x)

#endif

--
Matt Mackall : http://www.selenic.com : of or relating to the moon

2003-07-09 09:18:41

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Wednesday 09 July 2003 11:18, Andrew Morton wrote:
> Thomas Schlichter <[email protected]> wrote:
> > This gives following compile error when compiling the kernel with APM
> > support for UP:
> >
> > arch/i386/kernel/apm.c: In function `apm_bios_call':
> > arch/i386/kernel/apm.c:600: error: incompatible types in assignment
> > arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
> > arch/i386/kernel/apm.c:643: error: incompatible types in assignment
> >
> > The attached patch fixes this...
>
> Seems complex. I just have this:
>
>
> diff -puN arch/i386/kernel/apm.c~cpumask-apm-fix-2 arch/i386/kernel/apm.c
> --- 25/arch/i386/kernel/apm.c~cpumask-apm-fix-2 2003-07-08
> 23:09:23.000000000 -0700 +++ 25-akpm/arch/i386/kernel/apm.c 2003-07-08
> 23:28:50.000000000 -0700 @@ -528,7 +528,7 @@ static inline void
> apm_restore_cpus(cpum
> * No CPU lockdown needed on a uniprocessor
> */
>
> -#define apm_save_cpus() 0
> +#define apm_save_cpus() CPU_MASK_NONE
> #define apm_restore_cpus(x) (void)(x)
>
> #endif

I thought about this one, too, but I wasn't sure if gcc is able to optimize
away the assignment and the local cpumask_t variable with this oneliner...

But for me it is OK, too...

2003-07-09 09:24:09

by Marc-Christian Petersen

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Wednesday 09 July 2003 11:18, Andrew Morton wrote:

Hi Andrew,

> > arch/i386/kernel/apm.c: In function `apm_bios_call':
> > arch/i386/kernel/apm.c:600: error: incompatible types in assignment
> > arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
> > arch/i386/kernel/apm.c:643: error: incompatible types in assignment
> > The attached patch fixes this...
> Seems complex. I just have this:
>
>
> diff -puN arch/i386/kernel/apm.c~cpumask-apm-fix-2 arch/i386/kernel/apm.c
> --- 25/arch/i386/kernel/apm.c~cpumask-apm-fix-2 2003-07-08
> 23:09:23.000000000 -0700 +++ 25-akpm/arch/i386/kernel/apm.c 2003-07-08
> 23:28:50.000000000 -0700 @@ -528,7 +528,7 @@ static inline void
> apm_restore_cpus(cpum
> * No CPU lockdown needed on a uniprocessor
> */
>
> -#define apm_save_cpus() 0
> +#define apm_save_cpus() CPU_MASK_NONE
> #define apm_restore_cpus(x) (void)(x)
>
> #endif
>
better use the attached one ;)

ciao, Marc


Attachments:
(No filename) (939.00 B)
15_fixup-apm-small.patch (640.00 B)
Download all attachments

2003-07-09 11:07:26

by Jan De Luyck

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Wednesday 09 July 2003 11:38, Marc-Christian Petersen wrote:
>
> better use the attached one ;)
>
> ciao, Marc

Still bombs out:

CC [M] arch/i386/kernel/apm.o
arch/i386/kernel/apm.c: In function `apm_bios_call':
arch/i386/kernel/apm.c:601: error: syntax error before '{' token
arch/i386/kernel/apm.c:595: warning: unused variable `saved_fs'
arch/i386/kernel/apm.c:595: warning: unused variable `saved_gs'
arch/i386/kernel/apm.c:596: warning: unused variable `flags'
arch/i386/kernel/apm.c:598: warning: unused variable `cpu'
arch/i386/kernel/apm.c:599: warning: unused variable `save_desc_40'
arch/i386/kernel/apm.c: At top level:
arch/i386/kernel/apm.c:603: warning: type defaults to `int' in declaration of
`cpu'
arch/i386/kernel/apm.c:603: error: braced-group within expression allowed only
inside a function
arch/i386/kernel/apm.c:603: error: syntax error before ')' token
arch/i386/kernel/apm.c:604: warning: type defaults to `int' in declaration of
`save_desc_40'
arch/i386/kernel/apm.c:604: error: incompatible types in initialization
arch/i386/kernel/apm.c:604: error: initializer element is not constant
arch/i386/kernel/apm.c:604: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:605: warning: type defaults to `int' in declaration of
`cpu_gdt_table'
arch/i386/kernel/apm.c:605: error: variable-size type declared outside of any
function
arch/i386/kernel/apm.c:605: error: variable-sized object may not be
initialized
arch/i386/kernel/apm.c:605: error: conflicting types for `cpu_gdt_table'
include/asm/desc.h:14: error: previous declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:605: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:607: error: syntax error before "do"
arch/i386/kernel/apm.c:607: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:607: warning: type defaults to `int' in declaration of
`__dummy2'
arch/i386/kernel/apm.c:607: error: syntax error before "void"
arch/i386/kernel/apm.c:609: error: syntax error before "volatile"
arch/i386/kernel/apm.c:610: warning: type defaults to `int' in declaration of
`apm_bios_call_asm'
arch/i386/kernel/apm.c:610: warning: parameter names (without types) in
function declaration
arch/i386/kernel/apm.c:610: error: conflicting types for `apm_bios_call_asm'
include/asm-i386/mach-default/apm.h:31: error: previous declaration of
`apm_bios_call_asm'
arch/i386/kernel/apm.c:610: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:611: error: syntax error before "volatile"
arch/i386/kernel/apm.c:612: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:612: warning: type defaults to `int' in declaration of
`__dummy2'
arch/i386/kernel/apm.c:612: error: syntax error before "void"
arch/i386/kernel/apm.c:613: warning: type defaults to `int' in declaration of
`cpu_gdt_table'
arch/i386/kernel/apm.c:613: error: variable-size type declared outside of any
function
arch/i386/kernel/apm.c:613: error: variable-sized object may not be
initialized
arch/i386/kernel/apm.c:613: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:614: error: syntax error before "do"
arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
arch/i386/kernel/apm.c:644: error: syntax error before '{' token
arch/i386/kernel/apm.c:636: warning: unused variable `error'
arch/i386/kernel/apm.c:637: warning: unused variable `saved_fs'
arch/i386/kernel/apm.c:637: warning: unused variable `saved_gs'
arch/i386/kernel/apm.c:638: warning: unused variable `flags'
arch/i386/kernel/apm.c:640: warning: unused variable `cpu'
arch/i386/kernel/apm.c:641: warning: unused variable `save_desc_40'
arch/i386/kernel/apm.c: At top level:
arch/i386/kernel/apm.c:646: warning: type defaults to `int' in declaration of
`cpu'
arch/i386/kernel/apm.c:646: error: redefinition of `cpu'
arch/i386/kernel/apm.c:603: error: `cpu' previously defined here
arch/i386/kernel/apm.c:646: error: braced-group within expression allowed only
inside a function
arch/i386/kernel/apm.c:646: error: syntax error before ')' token
arch/i386/kernel/apm.c:647: warning: type defaults to `int' in declaration of
`save_desc_40'
arch/i386/kernel/apm.c:647: error: redefinition of `save_desc_40'
arch/i386/kernel/apm.c:604: error: `save_desc_40' previously defined here
arch/i386/kernel/apm.c:647: error: initializer element is not constant
arch/i386/kernel/apm.c:647: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:648: warning: type defaults to `int' in declaration of
`cpu_gdt_table'
arch/i386/kernel/apm.c:648: error: variable-size type declared outside of any
function
arch/i386/kernel/apm.c:648: error: variable-sized object may not be
initialized
arch/i386/kernel/apm.c:648: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:650: error: syntax error before "do"
arch/i386/kernel/apm.c:650: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:650: warning: type defaults to `int' in declaration of
`__dummy2'
arch/i386/kernel/apm.c:650: error: syntax error before "void"
arch/i386/kernel/apm.c:652: error: syntax error before "volatile"
arch/i386/kernel/apm.c:653: warning: type defaults to `int' in declaration of
`error'
arch/i386/kernel/apm.c:653: error: `func' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: `ebx_in' undeclared here (not in a
function)
arch/i386/kernel/apm.c:653: error: `ecx_in' undeclared here (not in a
function)
arch/i386/kernel/apm.c:653: error: `eax' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: initializer element is not constant
arch/i386/kernel/apm.c:653: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:654: error: syntax error before "volatile"
arch/i386/kernel/apm.c:655: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:655: warning: type defaults to `int' in declaration of
`__dummy2'
arch/i386/kernel/apm.c:655: error: syntax error before "void"
arch/i386/kernel/apm.c:656: warning: type defaults to `int' in declaration of
`cpu_gdt_table'
arch/i386/kernel/apm.c:656: error: conflicting types for `cpu_gdt_table'
arch/i386/kernel/apm.c:648: error: previous declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:656: warning: data definition has no type or storage
class
arch/i386/kernel/apm.c:657: error: syntax error before "do"
arch/i386/kernel/apm.c: In function `apm_power_off':
arch/i386/kernel/apm.c:922: warning: braces around scalar initializer
arch/i386/kernel/apm.c:922: warning: (near initialization for `(anonymous)')
arch/i386/kernel/apm.c:922: error: array index in non-array initializer
arch/i386/kernel/apm.c:922: error: (near initialization for `(anonymous)')
arch/i386/kernel/apm.c:922: error: invalid initializer
arch/i386/kernel/apm.c:922: error: (near initialization for `(anonymous)')
{standard input}: Assembler messages:
{standard input}:502: Error: symbol `cpu' is already defined
{standard input}:508: Error: symbol `save_desc_40' is already defined
make[2]: *** [arch/i386/kernel/apm.o] Error 1
make[1]: *** [arch/i386/kernel] Error 2
make[1]: Leaving directory `/usr/src/linux'
make: *** [stamp-build] Error 2
laptop:/usr/src/linux# '

2003-07-09 13:08:36

by Ramón Rey Vicente

[permalink] [raw]
Subject: Re: 2.5.74-mm3

arch/i386/kernel/apm.c: En la funci?n `apm_bios_call':
arch/i386/kernel/apm.c:601: error: error sint?ctico before '{' token
arch/i386/kernel/apm.c:595: aviso: unused variable `saved_fs'
arch/i386/kernel/apm.c:595: aviso: unused variable `saved_gs'
arch/i386/kernel/apm.c:596: aviso: unused variable `flags'
arch/i386/kernel/apm.c:598: aviso: unused variable `cpu'
arch/i386/kernel/apm.c:599: aviso: unused variable `save_desc_40'
arch/i386/kernel/apm.c: En el nivel principal:
arch/i386/kernel/apm.c:603: aviso: type defaults to `int' in declaration of `cpu'
arch/i386/kernel/apm.c:603: error: braced-group within expression allowed only inside a function
arch/i386/kernel/apm.c:603: error: error sint?ctico before ')' token
arch/i386/kernel/apm.c:604: aviso: type defaults to `int' in declaration of `save_desc_40'
arch/i386/kernel/apm.c:604: error: incompatible types in inicializaci?n
arch/i386/kernel/apm.c:604: error: el elemento inicializador no es constante
arch/i386/kernel/apm.c:604: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:605: aviso: type defaults to `int' in declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:605: error: variable-size type declared outside of any function
arch/i386/kernel/apm.c:605: error: variable-sized object may not be initialized
arch/i386/kernel/apm.c:605: error: conflicting types for `cpu_gdt_table'
include/asm/desc.h:14: error: previous declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:605: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:607: error: error sint?ctico before "do"
arch/i386/kernel/apm.c:607: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:607: aviso: type defaults to `int' in declaration of `__dummy2'
arch/i386/kernel/apm.c:607: error: error sint?ctico before "void"
arch/i386/kernel/apm.c:609: error: error sint?ctico before "volatile"
arch/i386/kernel/apm.c:610: aviso: type defaults to `int' in declaration of `apm_bios_call_asm'
arch/i386/kernel/apm.c:610: aviso: nombres de par?metros (sin tipos) en la declaraci?n de la funci?n
arch/i386/kernel/apm.c:610: error: conflicting types for `apm_bios_call_asm'
include/asm-i386/mach-default/apm.h:31: error: previous declaration of `apm_bios_call_asm'
arch/i386/kernel/apm.c:610: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:611: error: error sint?ctico before "volatile"
arch/i386/kernel/apm.c:612: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:612: aviso: type defaults to `int' in declaration of `__dummy2'
arch/i386/kernel/apm.c:612: error: error sint?ctico before "void"
arch/i386/kernel/apm.c:613: aviso: type defaults to `int' in declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:613: error: variable-size type declared outside of any function
arch/i386/kernel/apm.c:613: error: variable-sized object may not be initialized
arch/i386/kernel/apm.c:613: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:614: error: error sint?ctico before "do"
arch/i386/kernel/apm.c: En la funci?n `apm_bios_call_simple':
arch/i386/kernel/apm.c:644: error: error sint?ctico before '{' token
arch/i386/kernel/apm.c:636: aviso: unused variable `error'
arch/i386/kernel/apm.c:637: aviso: unused variable `saved_fs'
arch/i386/kernel/apm.c:637: aviso: unused variable `saved_gs'
arch/i386/kernel/apm.c:638: aviso: unused variable `flags'
arch/i386/kernel/apm.c:640: aviso: unused variable `cpu'
arch/i386/kernel/apm.c:641: aviso: unused variable `save_desc_40'
arch/i386/kernel/apm.c: En el nivel principal:
arch/i386/kernel/apm.c:646: aviso: type defaults to `int' in declaration of `cpu'
arch/i386/kernel/apm.c:646: error: redefinition of `cpu'
arch/i386/kernel/apm.c:603: error: `cpu' previously defined here
arch/i386/kernel/apm.c:646: error: braced-group within expression allowed only inside a function
arch/i386/kernel/apm.c:646: error: error sint?ctico before ')' token
arch/i386/kernel/apm.c:647: aviso: type defaults to `int' in declaration of `save_desc_40'
arch/i386/kernel/apm.c:647: error: redefinition of `save_desc_40'
arch/i386/kernel/apm.c:604: error: `save_desc_40' previously defined here
arch/i386/kernel/apm.c:647: error: el elemento inicializador no es constante
arch/i386/kernel/apm.c:647: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:648: aviso: type defaults to `int' in declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:648: error: variable-size type declared outside of any function
arch/i386/kernel/apm.c:648: error: variable-sized object may not be initialized
arch/i386/kernel/apm.c:648: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:650: error: error sint?ctico before "do"
arch/i386/kernel/apm.c:650: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:650: aviso: type defaults to `int' in declaration of `__dummy2'
arch/i386/kernel/apm.c:650: error: error sint?ctico before "void"
arch/i386/kernel/apm.c:652: error: error sint?ctico before "volatile"
arch/i386/kernel/apm.c:653: aviso: type defaults to `int' in declaration of `error'
arch/i386/kernel/apm.c:653: error: `func' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: `ebx_in' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: `ecx_in' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: `eax' undeclared here (not in a function)
arch/i386/kernel/apm.c:653: error: el elemento inicializador no es constante
arch/i386/kernel/apm.c:653: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:654: error: error sint?ctico before "volatile"
arch/i386/kernel/apm.c:655: error: `flags' undeclared here (not in a function)
arch/i386/kernel/apm.c:655: aviso: type defaults to `int' in declaration of `__dummy2'
arch/i386/kernel/apm.c:655: error: error sint?ctico before "void"
arch/i386/kernel/apm.c:656: aviso: type defaults to `int' in declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:656: error: conflicting types for `cpu_gdt_table'
arch/i386/kernel/apm.c:648: error: previous declaration of `cpu_gdt_table'
arch/i386/kernel/apm.c:656: aviso: data definition has no type or storage class
arch/i386/kernel/apm.c:657: error: error sint?ctico before "do"
arch/i386/kernel/apm.c: En la funci?n `apm_power_off':
arch/i386/kernel/apm.c:922: aviso: llaves alrededor del inicializador escalar
arch/i386/kernel/apm.c:922: aviso: (near initialization for `(anonymous)')
arch/i386/kernel/apm.c:922: error: ?ndice de matriz en el inicializador que no es matriz
arch/i386/kernel/apm.c:922: error: (near initialization for `(anonymous)')
arch/i386/kernel/apm.c:922: error: inicializador inv?lido
arch/i386/kernel/apm.c:922: error: (near initialization for `(anonymous)')
{entrada est?ndar}: Mensajes del ensamblador:
{entrada est?ndar}:371: Error: el s?mbolo `cpu' ya est? definido
{entrada est?ndar}:377: Error: el s?mbolo `save_desc_40' ya est? definido
make[2]: *** [arch/i386/kernel/apm.o] Error 1
make[1]: *** [arch/i386/kernel] Error 2
make: *** [stamp-build] Error 2


Attachments:
LOG (6.93 kB)

2003-07-10 05:30:31

by Piet Delaney

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Wed, 2003-07-09 at 02:18, Andrew Morton wrote:
> Thomas Schlichter <[email protected]> wrote:
.
.
.
> Seems complex. I just have this:
>
>
> diff -puN arch/i386/kernel/apm.c~cpumask-apm-fix-2 arch/i386/kernel/apm.c
> --- 25/arch/i386/kernel/apm.c~cpumask-apm-fix-2 2003-07-08 23:09:23.000000000 -0700
> +++ 25-akpm/arch/i386/kernel/apm.c 2003-07-08 23:28:50.000000000 -0700
> @@ -528,7 +528,7 @@ static inline void apm_restore_cpus(cpum
> * No CPU lockdown needed on a uniprocessor
> */
>
> -#define apm_save_cpus() 0
> +#define apm_save_cpus() CPU_MASK_NONE
> #define apm_restore_cpus(x) (void)(x)

I tried this and got a parse error. So I assumed perhaps I
needed to upgrade to the latest C compiler to be able
to handle the assignment of a inline static initializer:

#define CPU_MASK_NONE { {[0 ... CPU_ARRAY_SIZE-1] = 0UL} }

I was disappointed that using gcc 3.3 didn't fix the problem:
----------------------------------------------------------------------
CC arch/i386/kernel/apm.o
arch/i386/kernel/apm.c: In function `apm_bios_call':
arch/i386/kernel/apm.c:599: error: parse error before '{' token
arch/i386/kernel/apm.c: In function `apm_bios_call_simple':
arch/i386/kernel/apm.c:642: error: parse error before '{' token
arch/i386/kernel/apm.c: In function `apm_power_off':
arch/i386/kernel/apm.c:920: warning: braces around scalar initializer
arch/i386/kernel/apm.c:920: warning: (near initialization for
`(anonymous)')
arch/i386/kernel/apm.c:920: error: array index in non-array initializer
arch/i386/kernel/apm.c:920: error: (near initialization for
`(anonymous)')
arch/i386/kernel/apm.c:920: error: invalid initializer
arch/i386/kernel/apm.c:920: error: (near initialization for
`(anonymous)')
------------------------------------------------------------------------------

I'll settle for Matt Mackall <[email protected]> fix for now:

+#define apm_save_cpus() (current->cpus_allowed)

I wonder why other, like Thomas Schlichter <[email protected]>,
had no problem with the CPU_MASK_NONE fix.

I tried adding the #include <linux/cpumask.h> that Marc-Christian
Petersen <[email protected]> sugested but it didn't help. Looks
like Jan De Luyck <[email protected]> had a similar result.

-piet

> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to [email protected]. For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
--
piet@http://www.piet.net

2003-07-10 05:52:51

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Wed, Jul 09, 2003 at 10:44:50PM -0700, Piet Delaney wrote:
> I'll settle for Matt Mackall <[email protected]> fix for now:
> +#define apm_save_cpus() (current->cpus_allowed)
> I wonder why other, like Thomas Schlichter <[email protected]>,
> had no problem with the CPU_MASK_NONE fix.
> I tried adding the #include <linux/cpumask.h> that Marc-Christian
> Petersen <[email protected]> sugested but it didn't help. Looks
> like Jan De Luyck <[email protected]> had a similar result.

Ugh. Fixing.


-- wli

2003-07-10 06:54:56

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Wed, Jul 09, 2003 at 10:44:50PM -0700, Piet Delaney wrote:
>> I'll settle for Matt Mackall <[email protected]> fix for now:
>> +#define apm_save_cpus() (current->cpus_allowed)
>> I wonder why other, like Thomas Schlichter <[email protected]>,
>> had no problem with the CPU_MASK_NONE fix.
>> I tried adding the #include <linux/cpumask.h> that Marc-Christian
>> Petersen <[email protected]> sugested but it didn't help. Looks
>> like Jan De Luyck <[email protected]> had a similar result.

On Wed, Jul 09, 2003 at 11:08:41PM -0700, William Lee Irwin III wrote:
> Ugh. Fixing.


diff -prauN mm3-2.5.74-1/arch/i386/kernel/apm.c mm3-2.5.74-apm-1/arch/i386/kernel/apm.c
--- mm3-2.5.74-1/arch/i386/kernel/apm.c 2003-07-09 00:03:25.000000000 -0700
+++ mm3-2.5.74-apm-1/arch/i386/kernel/apm.c 2003-07-10 00:03:31.000000000 -0700
@@ -528,7 +528,7 @@ static inline void apm_restore_cpus(cpum
* No CPU lockdown needed on a uniprocessor
*/

-#define apm_save_cpus() 0
+#define apm_save_cpus() ({ cpumask_t __mask__ = CPU_MASK_NONE; __mask__; })
#define apm_restore_cpus(x) (void)(x)

#endif

2003-07-10 07:07:31

by Andrew Morton

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

William Lee Irwin III <[email protected]> wrote:
>
> -#define apm_save_cpus() 0
> +#define apm_save_cpus() ({ cpumask_t __mask__ = CPU_MASK_NONE; __mask__; })

Taking a look at what the APM code is actually doing, I think using
current->cpus_allowed just more sense in here.

Not that it matters at all.

2003-07-10 07:44:13

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

William Lee Irwin III <[email protected]> wrote:
>> -#define apm_save_cpus() 0
>> +#define apm_save_cpus() ({ cpumask_t __mask__ = CPU_MASK_NONE; __mask__; })

On Thu, Jul 10, 2003 at 12:18:53AM -0700, Andrew Morton wrote:
> Taking a look at what the APM code is actually doing, I think using
> current->cpus_allowed just more sense in here.
> Not that it matters at all.

Going beyond pure substitution:


diff -prauN mm3-2.5.74-1/arch/i386/kernel/apm.c mm3-2.5.74-apm-1/arch/i386/kernel/apm.c
--- mm3-2.5.74-1/arch/i386/kernel/apm.c 2003-07-09 00:03:25.000000000 -0700
+++ mm3-2.5.74-apm-1/arch/i386/kernel/apm.c 2003-07-10 00:53:51.000000000 -0700
@@ -506,8 +506,6 @@ static void apm_error(char *str, int err
* Lock APM functionality to physical CPU 0
*/

-#ifdef CONFIG_SMP
-
static cpumask_t apm_save_cpus(void)
{
cpumask_t x = current->cpus_allowed;
@@ -522,17 +520,6 @@ static inline void apm_restore_cpus(cpum
set_cpus_allowed(current, mask);
}

-#else
-
-/*
- * No CPU lockdown needed on a uniprocessor
- */
-
-#define apm_save_cpus() 0
-#define apm_restore_cpus(x) (void)(x)
-
-#endif
-
/*
* These are the actual BIOS calls. Depending on APM_ZERO_SEGS and
* apm_info.allow_ints, we are being really paranoid here! Not only

2003-07-10 07:57:09

by Seth Chromick

[permalink] [raw]
Subject: hptraid.o -- No array found?

I have XP and Gentoo linux installed. In XP, my IDE RAID0 config can be
seen and used flawlessly (highpoint). In linux, modprobe ataraid works
fine, but modprobing hptraid gives me "Raid array not found" a few times
and stops. Any ideas? I've googled around to no avail...

2003-07-10 08:01:10

by Piet Delaney

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - module-init-tools: necessary to replace root copies?

I followed your suggestion of installing the module-init-tools
to get around the "make modules_install" problem. I modified
the kernel Makefile to point to /usr/local:

#DEPMOD = /sbin/depmod
DEPMOD = /usr/local/sbin/depmod

I expect it's likely necessary to copy the /usr/local
copies over the / copies so that they are available to
the boot code; Perhaps not.

I thought I check to see how you and/or others did
to for using the newer module-init-tools.

Also, do you think it's better to enable the use
frame pointer when using kgdb. In the past I thought
I had problems with modules due to my enabling the
frame pointer being used.

-piet

--
piet@http://www.piet.net

2003-07-10 08:03:13

by Piet Delaney

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - module-init-tools: necessary to replace root copies?

I followed your suggestion of installing the module-init-tools
to get around the "make modules_install" problem. I modified
the kernel Makefile to point to /usr/local:

#DEPMOD = /sbin/depmod
DEPMOD = /usr/local/sbin/depmod

I expect it's likely necessary to copy the /usr/local
copies over the / copies so that they are available to
the boot code; Perhaps not.

I thought I check to see how you and/or others did
to for using the newer module-init-tools.

Also, do you think it's better to enable the use
frame pointer when using kgdb. In the past I thought
I had problems with modules due to my enabling the
frame pointer being used.

-piet

--
piet@http://www.piet.net

2003-07-10 08:13:12

by Andrew Morton

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - module-init-tools: necessary to replace root copies?

Piet Delaney <piet@http://www.piet.net> wrote:
>
> Also, do you think it's better to enable the use
> frame pointer when using kgdb.

Enabled, definitely.

> In the past I thought
> I had problems with modules due to my enabling the
> frame pointer being used.

No, there are no such problems.

2003-07-10 09:11:33

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thu, Jul 10, 2003 at 11:22:56AM +0200, Thomas Schlichter wrote:
> Well, I didn't try the CPU_MASK_NONE fix. I am using my fix attached to my
> first mail, but Andrew ment it was too complex (your quoting from above). So
> he proposed the simpler fix, wich simply looked good to me...

Could you try the following?


diff -prauN mm3-2.5.74-1/arch/i386/kernel/apm.c mm3-2.5.74-apm-1/arch/i386/kernel/apm.c
--- mm3-2.5.74-1/arch/i386/kernel/apm.c 2003-07-09 00:03:25.000000000 -0700
+++ mm3-2.5.74-apm-1/arch/i386/kernel/apm.c 2003-07-10 00:53:51.000000000 -0700
@@ -506,8 +506,6 @@ static void apm_error(char *str, int err
* Lock APM functionality to physical CPU 0
*/

-#ifdef CONFIG_SMP
-
static cpumask_t apm_save_cpus(void)
{
cpumask_t x = current->cpus_allowed;
@@ -522,17 +520,6 @@ static inline void apm_restore_cpus(cpum
set_cpus_allowed(current, mask);
}

-#else
-
-/*
- * No CPU lockdown needed on a uniprocessor
- */
-
-#define apm_save_cpus() 0
-#define apm_restore_cpus(x) (void)(x)
-
-#endif
-
/*
* These are the actual BIOS calls. Depending on APM_ZERO_SEGS and
* apm_info.allow_ints, we are being really paranoid here! Not only

2003-07-10 09:09:13

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 07:44, Piet Delaney wrote:
> On Wed, 2003-07-09 at 02:18, Andrew Morton wrote:
> > Thomas Schlichter <[email protected]> wrote:
>
> .
> .
> .
>
> > Seems complex. I just have this:

~~snip~~

> I'll settle for Matt Mackall <[email protected]> fix for now:
>
> +#define apm_save_cpus() (current->cpus_allowed)
>
> I wonder why other, like Thomas Schlichter <[email protected]>,
> had no problem with the CPU_MASK_NONE fix.

Well, I didn't try the CPU_MASK_NONE fix. I am using my fix attached to my
first mail, but Andrew ment it was too complex (your quoting from above). So
he proposed the simpler fix, wich simply looked good to me...

> I tried adding the #include <linux/cpumask.h> that Marc-Christian
> Petersen <[email protected]> sugested but it didn't help. Looks
> like Jan De Luyck <[email protected]> had a similar result.
>
> -piet

Thomas

2003-07-10 09:29:27

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 11:27, William Lee Irwin III wrote:
> On Thu, Jul 10, 2003 at 11:22:56AM +0200, Thomas Schlichter wrote:
> > Well, I didn't try the CPU_MASK_NONE fix. I am using my fix attached to
> > my first mail, but Andrew ment it was too complex (your quoting from
> > above). So he proposed the simpler fix, wich simply looked good to me...
>
> Could you try the following?

OK, I tried it. For me it compiles!

But the size of the resulting objectfile's text section is about 64bytes
larger than with my patch. So it seems that gcc3.3 wasn't able to optimize
away all the unneeded stuff...

And I don't think my patch is that ugly, but hey, it's your decision...

Best regards
Thomas Schlichter

2003-07-10 09:33:06

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 11:27, William Lee Irwin III wrote:
>> Could you try the following?

On Thu, Jul 10, 2003 at 11:42:35AM +0200, Thomas Schlichter wrote:
> OK, I tried it. For me it compiles!
> But the size of the resulting objectfile's text section is about 64bytes
> larger than with my patch. So it seems that gcc3.3 wasn't able to optimize
> away all the unneeded stuff...
> And I don't think my patch is that ugly, but hey, it's your decision...

64B? Why do you care?


-- wli

2003-07-10 09:45:21

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 11:48, William Lee Irwin III wrote:
> On Thursday 10 July 2003 11:27, William Lee Irwin III wrote:
> >> Could you try the following?
>
> On Thu, Jul 10, 2003 at 11:42:35AM +0200, Thomas Schlichter wrote:
> > OK, I tried it. For me it compiles!
> > But the size of the resulting objectfile's text section is about 64bytes
> > larger than with my patch. So it seems that gcc3.3 wasn't able to
> > optimize away all the unneeded stuff...
> > And I don't think my patch is that ugly, but hey, it's your decision...
>
> 64B? Why do you care?

It's not the 64B...
I care about the unneeded but executed code!
But I'm a hopeless perfectionist caring about such nits...

And I don't know why everybody hates my patches... ;-(

Thomas

2003-07-10 10:14:35

by William Lee Irwin III

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 11:48, William Lee Irwin III wrote:
> It's not the 64B...
> I care about the unneeded but executed code!
> But I'm a hopeless perfectionist caring about such nits...

On Thu, Jul 10, 2003 at 11:59:49AM +0200, Thomas Schlichter wrote:
> And I don't know why everybody hates my patches... ;-(

It's not that anyone hates them, it's that
pass 1: the semantics (0 == empty cpu set) needed preserving
pass 2: remove code instead of changing redundant stuff

NFI YTF gcc doesn't optimize out the whole shebang.

At any rate, if we're pounding APM BIOS calls or apm_power_off()
like wild monkeys there's something far more disturbing going wrong
than 64B of code gcc couldn't optimize (it's probably due to some
jump target being aligned to death or some such nonsense).


-- wli

2003-07-10 10:35:08

by Thomas Schlichter

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thursday 10 July 2003 12:30, William Lee Irwin III wrote:
> On Thu, Jul 10, 2003 at 11:59:49AM +0200, Thomas Schlichter wrote:
> > And I don't know why everybody hates my patches... ;-(

That was just fun, but OK, I forgot the 'fun' tags... ;-)

> It's not that anyone hates them, it's that
> pass 1: the semantics (0 == empty cpu set) needed preserving

Well the original code already had 2 different semantics:
In the MP case it returned the mask of currently allowed CPUs which should
have been 1 for UP but was 0...

So as the value returned by apm_save_cpus() was only used for apm_restore_cpus
() I optimized it away. Which was just an other change of the semantics...ACK

> pass 2: remove code instead of changing redundant stuff

ACK

> NFI YTF gcc doesn't optimize out the whole shebang.
>
> At any rate, if we're pounding APM BIOS calls or apm_power_off()
> like wild monkeys there's something far more disturbing going wrong
> than 64B of code gcc couldn't optimize (it's probably due to some
> jump target being aligned to death or some such nonsense).

OK, I see you're right and your actual patch looks better to me because it
makes the semantics consistent! So come on and let's take it into the
tree...!

Thomas

2003-07-10 12:08:13

by Alan

[permalink] [raw]
Subject: Re: hptraid.o -- No array found?

On Iau, 2003-07-10 at 05:09, Seth Chromick wrote:
> I have XP and Gentoo linux installed. In XP, my IDE RAID0 config can be
> seen and used flawlessly (highpoint). In linux, modprobe ataraid works
> fine, but modprobing hptraid gives me "Raid array not found" a few times
> and stops. Any ideas? I've googled around to no avail...

hptraid only understands a small subset of the disk layouts so not all
forms are known. Wilfried has done some really good work on this so more
formats are known by the later drivers.

Unfortunately HPT don't seem keen to document their disk layout.

2003-07-10 18:06:35

by Valdis Klētnieks

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Tue, 08 Jul 2003 22:35:48 PDT, Andrew Morton <[email protected]> said:

> ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.5/2.5.74/2.5.74-mm3/

OK, I'm finally getting around to actually commenting, this has been a niggling issue for
a while...

> All 113 patches:

> 64-bit-dev_t-kdev_t.patch
> 64-bit dev_t and kdev_t

Yes, this patch says "not ready for prime time, it breaks things".

In particular, this gives the device-mapper userspace indigestion, because the
ioctl passes something other than a 64-bit kdev_t in from libdevmapper. Upshot
is that the LVM2 'vgchange -ay' fails gloriously.

Workaround: Compile the devmapper/LVM stuff with a private copy of include/
linux/kdev_t.h that matches the one the kernel uses. No, I didn't actually get
that to work, so I backed out the 64-bit patch...

(And no, the recent devmapper/LVM2 stuff posted doesn't fix this).


Attachments:
(No filename) (226.00 B)

2003-07-11 08:11:13

by Joe Thornber

[permalink] [raw]
Subject: Re: 2.5.74-mm3

On Thu, Jul 10, 2003 at 02:21:08PM -0400, [email protected] wrote:
> On Tue, 08 Jul 2003 22:35:48 PDT, Andrew Morton <[email protected]> said:
>
> > ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.5/2.5.74/2.5.74-mm3/
>
> OK, I'm finally getting around to actually commenting, this has been a niggling issue for
> a while...
>
> > All 113 patches:
>
> > 64-bit-dev_t-kdev_t.patch
> > 64-bit dev_t and kdev_t
>
> Yes, this patch says "not ready for prime time, it breaks things".
>
> In particular, this gives the device-mapper userspace indigestion, because the
> ioctl passes something other than a 64-bit kdev_t in from libdevmapper. Upshot
> is that the LVM2 'vgchange -ay' fails gloriously.
>
> Workaround: Compile the devmapper/LVM stuff with a private copy of include/
> linux/kdev_t.h that matches the one the kernel uses. No, I didn't actually get
> that to work, so I backed out the 64-bit patch...
>
> (And no, the recent devmapper/LVM2 stuff posted doesn't fix this).

The v1 ioctl interface passes the dev in as a __kernel_dev_t, so
unfortunately if you change the size of __kernel_dev_t you will have
to rebuild the tools.

The v4 ioctl interface just uses a __u64 which I hope will be future
proof.

- Joe

2003-07-11 14:42:33

by Matt Mackall

[permalink] [raw]
Subject: Re: 2.5.74-mm3 - apm_save_cpus() Macro still bombs out

On Thu, Jul 10, 2003 at 03:30:22AM -0700, William Lee Irwin III wrote:
> On Thursday 10 July 2003 11:48, William Lee Irwin III wrote:
> > It's not the 64B...
> > I care about the unneeded but executed code!
> > But I'm a hopeless perfectionist caring about such nits...
>
> On Thu, Jul 10, 2003 at 11:59:49AM +0200, Thomas Schlichter wrote:
> > And I don't know why everybody hates my patches... ;-(
>
> It's not that anyone hates them, it's that
> pass 1: the semantics (0 == empty cpu set) needed preserving
> pass 2: remove code instead of changing redundant stuff
>
> NFI YTF gcc doesn't optimize out the whole shebang.

Probably would if inline were added to the function spec?

If we're going to worry about space, we'd start by worrying about the
existence of current->cpus_allowed in the UP case.

> At any rate, if we're pounding APM BIOS calls or apm_power_off()
> like wild monkeys there's something far more disturbing going wrong
> than 64B of code gcc couldn't optimize (it's probably due to some
> jump target being aligned to death or some such nonsense).

I much prefer the removal of #ifdef approach - would have prevented
the bug getting out in the first place.

--
Matt Mackall : http://www.selenic.com : of or relating to the moon

2003-07-11 15:49:08

by Anton Blanchard

[permalink] [raw]
Subject: Re: 2.5.74-mm3


> The v1 ioctl interface passes the dev in as a __kernel_dev_t, so
> unfortunately if you change the size of __kernel_dev_t you will have
> to rebuild the tools.
>
> The v4 ioctl interface just uses a __u64 which I hope will be future
> proof.

This was the only thing that made the 32bit ioctls different to the 64bit
ones on ppc64, so changing it to __u64 is a good thing.

Anton