2.4.0-test3 sys_ctrler fix.
Subsystems (2)
PATCH 1/1 2.4.0-test3 sys_ctrler fix.
here is a patch against 2.4.0-test3 as of yesterday (i.e. against the version with broken timer.c & idle.c). I was having real problems getting the BK rsync stuff until just now...
This patch fixes the cross-referencing of sys_ctrler - a variable indicating the ADB controller type (CUDA or PMU).
It is quite wide-ranging and affected pmac_setup, xmon, nvram, time, start, via-cuda, via-pmu & dmasound.
It may already have been fixed in 2.4.0-test4 (I just noticed that bitkeeper has changed).
====
I'll do a separate patch against 2.4.0-test3 for the dmasound stuff (once I've checked it out a bit more).
If you're desperate to try the sound then add a line
extern sys_ctrler_t sys_ctrlr ;
anywhere after machdep.h has been included - this should fix anyone else who has a G3/desktop (with the dmasound sources from test3).
It *might* fix PB problems too (but I can't be certain).
====
It needs the scrutiny of a more experienced bunch - I may not have got the conditionalisation right for all PPC platform variants... please be gentle-ish...
Iain.
arch/ppc/kernel/pmac_nvram.c +1 -0
@@ -70,6 +70,7 @@extern int pmac_newworld; +extern sys_ctrler_t sys_ctrler ;static u8 chrp_checksum (struct chrp_header * hdr)
arch/ppc/kernel/pmac_setup.c +2 -0
@@ -94,6 +94,8 @@extern void pckbd_init_hw (void );extern void pmac_nvram_update (void ); +sys_ctrler_t sys_ctrler =0 ; +unsigned char drive_info;int ppc_override_l2cr =0 ;
arch/ppc/kernel/pmac_time.c +2 -0
@@ -31,6 +31,8 @@extern rwlock_t xtime_lock; +extern sys_ctrler_t sys_ctrler ; +/* Apparently the RTC stores seconds since 1 Jan 1904 */ #define RTC_OFFSET 2082844800
arch/ppc/kernel/ppc_ksyms.c +4 -0
@@ -61,6 +61,8 @@int abs (int );extern unsigned long ret_to_user_hook; +extern sys_ctrler_t sys_ctrler ; +EXPORT_SYMBOL (clear_page);EXPORT_SYMBOL (do_signal);EXPORT_SYMBOL (syscall_trace);
@@ -198,6 +200,8 @@EXPORT_SYMBOL (_machine);#endif EXPORT_SYMBOL (ppc_md); + +EXPORT_SYMBOL_NOVERS (sys_ctrler) ;#ifdef CONFIG_ADB /*
arch/ppc/xmon/start.c +2 -0
@@ -27,6 +27,8 @@static int xmon_use_sccb =0 ;static struct device_node *macio_node; +extern sys_ctrler_t sys_ctrler ; +#define TB_SPEED 25000000static inline unsigned int readtb (void )
drivers/macintosh/via-cuda.c +4 -0
@@ -32,6 +32,10 @@static volatile unsigned char *via; +#ifdef CONFIG_PPC +extern sys_ctrler_t sys_ctrler ; +#endif +#ifdef CONFIG_MAC #define CUDA_IRQ IRQ_MAC_ADB#define __openfirmware
drivers/macintosh/via-pmu.c +2 -0
@@ -156,6 +156,8 @@extern int grackle_pcibios_write_config_word (unsigned char bus,unsigned char dev_fn,unsigned char offset,unsigned short val); +extern sys_ctrler_t sys_ctrler ; +/* * This table indicates for each PMU opcode: * - the number of data bytes to be sent with the command, or -1
include/asm-ppc/machdep.h +2 -2
@@ -87,9 +87,9 @@* Power macintoshes have either a CUDA or a PMU controlling * system reset, power, NVRAM, RTC. */ -enum sys_ctrler_kind { +typedef enum sys_ctrler_kind {SYS_CTRLER_CUDA =1 ,SYS_CTRLER_PMU =2 , -} sys_ctrler; +}sys_ctrler_t ;#endif /* _PPC_MACHDEP_H */