mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2025-02-02 18:41:07 +02:00
More rdc fixes, thanks to Daniel Gimpelevich
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@8378 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
20deea5f7c
commit
795c5b1b26
@ -23,7 +23,7 @@ include $(INCLUDE_DIR)/kernel-build.mk
|
|||||||
ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),y)
|
ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),y)
|
||||||
define Kernel/SetInitramfs
|
define Kernel/SetInitramfs
|
||||||
echo "r6040 parent=wlan0" > $(TARGET_DIR)/etc/modules.d/99-r6040
|
echo "r6040 parent=wlan0" > $(TARGET_DIR)/etc/modules.d/99-r6040
|
||||||
$(RM) -f $(TARGET_DIR)/sbin/init
|
$(RM) $(TARGET_DIR)/sbin/init
|
||||||
ln -s /etc/preinit $(TARGET_DIR)/sbin/init
|
ln -s /etc/preinit $(TARGET_DIR)/sbin/init
|
||||||
sed -i 's,exec /sbin/init,exec /bin/busybox init,g' $(TARGET_DIR)/etc/preinit
|
sed -i 's,exec /sbin/init,exec /bin/busybox init,g' $(TARGET_DIR)/etc/preinit
|
||||||
sed -i 's,/sbin/init,/bin/busybox init,g' $(TARGET_DIR)/init
|
sed -i 's,/sbin/init,/bin/busybox init,g' $(TARGET_DIR)/init
|
||||||
|
@ -301,7 +301,7 @@ CONFIG_X86_MSR=y
|
|||||||
CONFIG_X86_POPAD_OK=y
|
CONFIG_X86_POPAD_OK=y
|
||||||
CONFIG_X86_PPRO_FENCE=y
|
CONFIG_X86_PPRO_FENCE=y
|
||||||
CONFIG_X86_RDC=y
|
CONFIG_X86_RDC=y
|
||||||
# CONFIG_X86_REBOOTFIXUPS is not set
|
CONFIG_X86_REBOOTFIXUPS=y
|
||||||
# CONFIG_X86_SUMMIT is not set
|
# CONFIG_X86_SUMMIT is not set
|
||||||
# CONFIG_X86_UP_APIC is not set
|
# CONFIG_X86_UP_APIC is not set
|
||||||
# CONFIG_X86_VISWS is not set
|
# CONFIG_X86_VISWS is not set
|
||||||
|
@ -38,9 +38,9 @@ static struct mtd_partition rdc3210_parts[] =
|
|||||||
#endif
|
#endif
|
||||||
{ name: "bootldr", offset: 0x003E0000, size: 0x00020000 }, /* 128 KB */
|
{ name: "bootldr", offset: 0x003E0000, size: 0x00020000 }, /* 128 KB */
|
||||||
#elif CONFIG_MTD_RDC3210_SIZE == 0x200000
|
#elif CONFIG_MTD_RDC3210_SIZE == 0x200000
|
||||||
{ name: "linux", offset: 0x00010000, size: 0x001E0000 },
|
{ name: "linux", offset: 0x00008000, size: 0x001E8000 },
|
||||||
{ name: "romfs", offset: 0x000D0000, size: 0x00120000 },
|
{ name: "romfs", offset: 0x000C8000, size: 0x00128000 },
|
||||||
{ name: "nvram", offset: 0x00000000, size: 0x00010000 }, /* 64 KB */
|
{ name: "nvram", offset: 0x00000000, size: 0x00008000 }, /* 64 KB */
|
||||||
#ifdef CONFIG_MTD_RDC3210_FACTORY_PRESENT
|
#ifdef CONFIG_MTD_RDC3210_FACTORY_PRESENT
|
||||||
#error Unsupported configuration!
|
#error Unsupported configuration!
|
||||||
#endif
|
#endif
|
||||||
|
@ -25,20 +25,20 @@ define Image/Build/ar525w
|
|||||||
touch $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
touch $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
mv $(KDIR)/root.$(1) $(KDIR)/root.tmp
|
mv $(KDIR)/root.$(1) $(KDIR)/root.tmp
|
||||||
dd of=$(KDIR)/root.$(1) if=$(KDIR)/root.tmp $(call trxalign/$(1)) conv=sync
|
dd of=$(KDIR)/root.$(1) if=$(KDIR)/root.tmp $(call trxalign/$(1)) conv=sync
|
||||||
$(RM) -f $(KDIR)/root.tmp
|
$(RM) $(KDIR)/root.tmp
|
||||||
$(STAGING_DIR_HOST)/bin/airlink -b 1 -j $(shell bash -c 'echo $$[$(3)]') $(KDIR)/bzImage $(KDIR)/root.$(1) $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
$(STAGING_DIR_HOST)/bin/airlink -b 1 -j $(shell bash -c 'echo $$[$(3)]') $(KDIR)/bzImage $(KDIR)/root.$(1) $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Image/Build/wl153
|
define Image/Build/wl153
|
||||||
echo $(shell ls -l $(KDIR)/bzImage | sed -r 's/^[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+([^[:blank:]]+).+$$/\1/' | xargs printf '%.8x') > $(KDIR)/bzSize
|
ls -l $(KDIR)/bzImage | sed -r 's/^[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+([^[:blank:]]+).+$$$$/\1/' | xargs printf '%.8x' > $(KDIR)/bzSize
|
||||||
gzip -9c $(KDIR)/root.$(1) > $(KDIR)/root.$(1).gz
|
gzip -9c $(KDIR)/root.$(1) > $(KDIR)/root.$(1).gz
|
||||||
echo $(shell ls -l $(KDIR)/root.$(1).gz | sed -r 's/^[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+([^[:blank:]]+).+$$/\1/' | xargs printf '%.8x') > $(KDIR)/rdSize
|
ls -l $(KDIR)/root.$(1).gz | sed -r 's/^[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+[^[:blank:]]+[[:blank:]]+([^[:blank:]]+).+$$$$/\1/' | xargs printf '%.8x' > $(KDIR)/rdSize
|
||||||
echo -ne "\x$$$$(cut -c 7,8 < $(KDIR)/bzSize)\x$$$$(cut -c 5,6 < $(KDIR)/bzSize)\x$$$$(cut -c 3,4 < $(KDIR)/bzSize)\x$$$$(cut -c 1,2 < $(KDIR)/bzSize)" > $(KDIR)/bzSize.tmp
|
echo -ne "\x$$$$(cut -c 7,8 < $(KDIR)/bzSize)\x$$$$(cut -c 5,6 < $(KDIR)/bzSize)\x$$$$(cut -c 3,4 < $(KDIR)/bzSize)\x$$$$(cut -c 1,2 < $(KDIR)/bzSize)" > $(KDIR)/bzSize.tmp
|
||||||
echo -n 'CSYS' > $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
echo -n 'CSYS' > $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
cat $(KDIR)/bzSize.tmp >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
cat $(KDIR)/bzSize.tmp >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
echo -ne "\x$$$$(cut -c 7,8 < $(KDIR)/rdSize)\x$$$$(cut -c 5,6 < $(KDIR)/rdSize)\x$$$$(cut -c 3,4 < $(KDIR)/rdSize)\x$$$$(cut -c 1,2 < $(KDIR)/rdSize)WRRM" >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
echo -ne "\x$$$$(cut -c 7,8 < $(KDIR)/rdSize)\x$$$$(cut -c 5,6 < $(KDIR)/rdSize)\x$$$$(cut -c 3,4 < $(KDIR)/rdSize)\x$$$$(cut -c 1,2 < $(KDIR)/rdSize)WRRM" >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
cat $(KDIR)/bzSize.tmp $(KDIR)/bzImage $(KDIR)/root.$(1).gz >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
cat $(KDIR)/bzSize.tmp $(KDIR)/bzImage $(KDIR)/root.$(1).gz >> $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1)-$(2).img
|
||||||
rm -f $(KDIR)/bzSize.tmp $(KDIR)/bzSize $(KDIR)/rdSize
|
$(RM) $(KDIR)/bzSize.tmp $(KDIR)/bzSize $(KDIR)/rdSize
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Image/Build
|
define Image/Build
|
||||||
|
@ -39,3 +39,42 @@ diff -urN linux-2.6.19/arch/i386/mach-rdc/Makefile linux-2.6.19.new/arch/i386/ma
|
|||||||
+#
|
+#
|
||||||
+
|
+
|
||||||
+obj-$(CONFIG_X86_RDC) := gpio.o platform.o
|
+obj-$(CONFIG_X86_RDC) := gpio.o platform.o
|
||||||
|
--- timex.h 2007-08-07 10:44:03.816112250 -0700
|
||||||
|
+++ linux/include/asm-i386/timex.h 2007-08-07 10:48:47.905866750 -0700
|
||||||
|
@@ -11,6 +11,8 @@
|
||||||
|
|
||||||
|
#ifdef CONFIG_X86_ELAN
|
||||||
|
# define CLOCK_TICK_RATE 1189200 /* AMD Elan has different frequency! */
|
||||||
|
+#elif defined(CONFIG_X86_RDC)
|
||||||
|
+# define CLOCK_TICK_RATE 1041667 /* Underlying HZ for R8610 */
|
||||||
|
#else
|
||||||
|
# define CLOCK_TICK_RATE 1193182 /* Underlying HZ */
|
||||||
|
#endif
|
||||||
|
--- reboot_fixups.c 2007-08-07 12:02:00.908412250 -0700
|
||||||
|
+++ linux/arch/i386/kernel/reboot_fixups.c 2007-08-07 12:18:49.391438500 -0700
|
||||||
|
@@ -13,6 +13,17 @@
|
||||||
|
#include <linux/pci.h>
|
||||||
|
#include <asm/reboot_fixups.h>
|
||||||
|
#include <asm/msr.h>
|
||||||
|
+
|
||||||
|
+static void r8610_reset(struct pci_dev *dev)
|
||||||
|
+{
|
||||||
|
+ int i;
|
||||||
|
+
|
||||||
|
+ outl(0x80003840,0xCF8);
|
||||||
|
+ i=inl(0xCFC);
|
||||||
|
+ i |= 0x1600;
|
||||||
|
+ outl(i,0xCFC);
|
||||||
|
+ outb(1,0x92);
|
||||||
|
+}
|
||||||
|
|
||||||
|
static void cs5530a_warm_reset(struct pci_dev *dev)
|
||||||
|
{
|
||||||
|
@@ -40,6 +53,7 @@
|
||||||
|
};
|
||||||
|
|
||||||
|
static struct device_fixup fixups_table[] = {
|
||||||
|
+{ 0x17F3, 0x6030, r8610_reset },
|
||||||
|
{ PCI_VENDOR_ID_CYRIX, PCI_DEVICE_ID_CYRIX_5530_LEGACY, cs5530a_warm_reset },
|
||||||
|
{ PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_ISA, cs5536_warm_reset },
|
||||||
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user