* Compile error 2.4.15-pre4 on alpha
@ 2001-11-13 0:48 Donald Maner
2001-11-13 4:17 ` Jeff Garzik
0 siblings, 1 reply; 5+ messages in thread
From: Donald Maner @ 2001-11-13 0:48 UTC (permalink / raw)
To: Linux Kernel (E-mail)
Hello, I'm compiling on a PC164SX, and I'm getting this at the end. I'm
pretty sure the math stuff doesn't have anything to do w/ it, but just
incase:
make[2]: Entering directory
`/usr/users/donjr/linux-2.4.15-pre4/arch/alpha/math-emu'
gcc -D__KERNEL__ -I/usr/users/donjr/linux-2.4.15-pre4/include -Wall
-Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer
-fno-strict-aliasing -fno-common -pipe -mno-fp-regs -ffixed-8 -mcpu=ev5
-Wa,-mev6 -c -o math.o math.c
math.c: In function `alpha_fp_emul':
math.c:204: warning: right shift count is negative
math.c:204: warning: left shift count >= width of type
math.c:220: warning: left shift count is negative
math.c:238: warning: statement with no effect
math.c:258: warning: right shift count >= width of type
math.c:258: warning: right shift count >= width of type
math.c:262: warning: right shift count >= width of type
math.c:262: warning: right shift count >= width of type
math.c:270: warning: statement with no effect
math.c:270: warning: statement with no effect
math.c:270: warning: statement with no effect
math.c:277: warning: statement with no effect
math.c:277: warning: statement with no effect
math.c:277: warning: statement with no effect
math.c:99: warning: `SR_c' might be used uninitialized in this function
math.c:99: warning: `SR_s' might be used uninitialized in this function
math.c:99: warning: `SR_e' might be used uninitialized in this function
math.c:99: warning: `SR_f' might be used uninitialized in this function
math.c:100: warning: `DR_c' might be used uninitialized in this function
math.c:100: warning: `DR_s' might be used uninitialized in this function
math.c:100: warning: `DR_e' might be used uninitialized in this function
math.c:100: warning: `DR_f' might be used uninitialized in this function
gcc -D__KERNEL__ -I/usr/users/donjr/linux-2.4.15-pre4/include -c -o
qrnnd.o qrnnd.S
rm -f math-emu.o
ld -r -o math-emu.o math.o qrnnd.o
make[2]: Leaving directory
`/usr/users/donjr/linux-2.4.15-pre4/arch/alpha/math-emu'
make[1]: Leaving directory
`/usr/users/donjr/linux-2.4.15-pre4/arch/alpha/math-emu'
gcc -E -D__KERNEL__ -I/usr/users/donjr/linux-2.4.15-pre4/include -xc -P
arch/alpha/vmlinux.lds.in -o arch/alpha/vmlinux.lds
ld -static -T arch/alpha/vmlinux.lds -N arch/alpha/kernel/head.o
init/main.o init/version.o \
--start-group \
arch/alpha/kernel/kernel.o arch/alpha/mm/mm.o kernel/kernel.o
mm/mm.o fs/fs.o ipc/ipc.o arch/alpha/math-emu/math-emu.o \
drivers/char/char.o drivers/block/block.o drivers/misc/misc.o
drivers/net/net.o drivers/media/media.o drivers/ide/idedriver.o
drivers/scsi/scsidrv.o drivers/cdrom/driver.o drivers/pci/driver.o
drivers/video/video.o drivers/md/mddev.o \
net/network.o \
/usr/users/donjr/linux-2.4.15-pre4/arch/alpha/lib/lib.a
/usr/users/donjr/linux-2.4.15-pre4/lib/lib.a
/usr/users/donjr/linux-2.4.15-pre4/arch/alpha/lib/lib.a \
--end-group \
-o vmlinux
fs/fs.o: In function `cpuinfo_open':
fs/fs.o(.text+0x2cf88): undefined reference to `cpuinfo_op'
make: *** [vmlinux] Error 1
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: Compile error 2.4.15-pre4 on alpha 2001-11-13 0:48 Compile error 2.4.15-pre4 on alpha Donald Maner @ 2001-11-13 4:17 ` Jeff Garzik 2001-11-13 13:59 ` Ivan Kokshaysky 0 siblings, 1 reply; 5+ messages in thread From: Jeff Garzik @ 2001-11-13 4:17 UTC (permalink / raw) To: Donald Maner; +Cc: Linux Kernel (E-mail) Donald Maner wrote: > Hello, I'm compiling on a PC164SX, and I'm getting this at the end. I'm > pretty sure the math stuff doesn't have anything to do w/ it, but just > incase: [...] > fs/fs.o: In function `cpuinfo_open': > fs/fs.o(.text+0x2cf88): undefined reference to `cpuinfo_op' > make: *** [vmlinux] Error 1 looks like alpha needs to implement /proc/cpuinfo as seqfile, as Linus said. -- Jeff Garzik | Only so many songs can be sung Building 1024 | with two lips, two lungs, and one tongue. MandrakeSoft | - nomeansno ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Compile error 2.4.15-pre4 on alpha 2001-11-13 4:17 ` Jeff Garzik @ 2001-11-13 13:59 ` Ivan Kokshaysky 2001-11-14 15:48 ` Jeff Garzik 0 siblings, 1 reply; 5+ messages in thread From: Ivan Kokshaysky @ 2001-11-13 13:59 UTC (permalink / raw) To: Jeff Garzik, Richard Henderson; +Cc: Donald Maner, Linux Kernel (E-mail) On Mon, Nov 12, 2001 at 11:17:25PM -0500, Jeff Garzik wrote: > > fs/fs.o(.text+0x2cf88): undefined reference to `cpuinfo_op' > > make: *** [vmlinux] Error 1 > > looks like alpha needs to implement /proc/cpuinfo as seqfile, as Linus > said. Patch appended. Ivan. --- 2.4.15p4/arch/alpha/kernel/setup.c Sat Nov 3 04:39:20 2001 +++ linux/arch/alpha/kernel/setup.c Tue Nov 13 15:00:54 2001 @@ -30,6 +30,7 @@ #include <linux/ioport.h> #include <linux/bootmem.h> #include <linux/pci.h> +#include <linux/seq_file.h> #ifdef CONFIG_BLK_DEV_INITRD #include <linux/blk.h> @@ -1043,10 +1044,8 @@ get_nr_processors(struct percpu_struct * } -/* - * BUFFER is PAGE_SIZE bytes long. - */ -int get_cpuinfo(char *buffer) +static int +show_cpuinfo(struct seq_file *f, void *slot) { extern struct unaligned_stat { unsigned long count, va, pc; @@ -1058,14 +1057,15 @@ int get_cpuinfo(char *buffer) "EV68CX", "EV7", "EV79", "EV69" }; - struct percpu_struct *cpu; + struct percpu_struct *cpu = slot; unsigned int cpu_index; char *cpu_name; char *systype_name; char *sysvariation_name; - int len, nr_processors; + int nr_processors; - cpu = (struct percpu_struct*)((char*)hwrpb + hwrpb->processor_offset); + if (!cpu) + return 1; cpu_index = (unsigned) (cpu->type - 1); cpu_name = "Unknown"; if (cpu_index < N(cpu_names)) @@ -1076,8 +1076,7 @@ int get_cpuinfo(char *buffer) nr_processors = get_nr_processors(cpu, hwrpb->nr_processors); - len = sprintf(buffer, - "cpu\t\t\t: Alpha\n" + seq_printf(f, "cpu\t\t\t: Alpha\n" "cpu model\t\t: %s\n" "cpu variation\t\t: %ld\n" "cpu revision\t\t: %ld\n" @@ -1114,11 +1113,41 @@ int get_cpuinfo(char *buffer) platform_string(), nr_processors); #ifdef CONFIG_SMP - len += smp_info(buffer+len); + seq_printf(f, "cpus active\t\t: %d\n" + "cpu active mask\t\t: %016lx\n", + smp_num_cpus, cpu_present_mask); #endif - return len; + return 0; +} + +/* + * We show only CPU #0 info. + */ +static void * +c_start(struct seq_file *f, loff_t *pos) +{ + return *pos ? NULL : (char *)hwrpb + hwrpb->processor_offset; +} + +static void * +c_next(struct seq_file *f, void *v, loff_t *pos) +{ + return NULL; } + +static void +c_stop(struct seq_file *f, void *v) +{ +} + +struct seq_operations cpuinfo_op = { + start: c_start, + next: c_next, + stop: c_stop, + show: show_cpuinfo, +}; + static int alpha_panic_event(struct notifier_block *this, unsigned long event, --- 2.4.15p4/arch/alpha/kernel/proto.h Fri Mar 2 22:12:07 2001 +++ linux/arch/alpha/kernel/proto.h Tue Nov 13 13:50:59 2001 @@ -91,7 +91,6 @@ extern void unregister_srm_console(void) /* smp.c */ extern void setup_smp(void); -extern int smp_info(char *buffer); extern void handle_ipi(struct pt_regs *); extern void smp_percpu_timer_interrupt(struct pt_regs *); --- 2.4.15p4/arch/alpha/kernel/smp.c Mon Oct 8 23:37:11 2001 +++ linux/arch/alpha/kernel/smp.c Tue Nov 13 13:10:48 2001 @@ -1091,15 +1091,6 @@ flush_icache_page(struct vm_area_struct } } \f -int -smp_info(char *buffer) -{ - return sprintf(buffer, - "cpus active\t\t: %d\n" - "cpu active mask\t\t: %016lx\n", - smp_num_cpus, cpu_present_mask); -} -\f #if DEBUG_SPINLOCK void spin_unlock(spinlock_t * lock) ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Compile error 2.4.15-pre4 on alpha 2001-11-13 13:59 ` Ivan Kokshaysky @ 2001-11-14 15:48 ` Jeff Garzik 2001-11-14 16:49 ` Ivan Kokshaysky 0 siblings, 1 reply; 5+ messages in thread From: Jeff Garzik @ 2001-11-14 15:48 UTC (permalink / raw) To: Ivan Kokshaysky; +Cc: Richard Henderson, Donald Maner, Linux Kernel (E-mail) Ivan Kokshaysky wrote: > +/* > + * We show only CPU #0 info. > + */ > +static void * > +c_start(struct seq_file *f, loff_t *pos) > +{ > + return *pos ? NULL : (char *)hwrpb + hwrpb->processor_offset; > +} only cpu0? on SMP, cpu1/2/3/4 are not shown? -- Jeff Garzik | Only so many songs can be sung Building 1024 | with two lips, two lungs, and one tongue. MandrakeSoft | - nomeansno ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Compile error 2.4.15-pre4 on alpha 2001-11-14 15:48 ` Jeff Garzik @ 2001-11-14 16:49 ` Ivan Kokshaysky 0 siblings, 0 replies; 5+ messages in thread From: Ivan Kokshaysky @ 2001-11-14 16:49 UTC (permalink / raw) To: Jeff Garzik; +Cc: Richard Henderson, Donald Maner, Linux Kernel (E-mail) On Wed, Nov 14, 2001 at 10:48:28AM -0500, Jeff Garzik wrote: > only cpu0? on SMP, cpu1/2/3/4 are not shown? They are supposed to be identical. Currently we're only interested in a CPU type and number of processors. Ivan. ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2001-11-14 16:50 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2001-11-13 0:48 Compile error 2.4.15-pre4 on alpha Donald Maner 2001-11-13 4:17 ` Jeff Garzik 2001-11-13 13:59 ` Ivan Kokshaysky 2001-11-14 15:48 ` Jeff Garzik 2001-11-14 16:49 ` Ivan Kokshaysky
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox