nslu2-kernel: patch format, nslu2-power now uses ctrl-alt-del in 2.6.14
authorJohn Bowler <jbowler@nslu2-linux.org>
Sat, 29 Oct 2005 01:36:01 +0000 (01:36 +0000)
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>
Sat, 29 Oct 2005 01:36:01 +0000 (01:36 +0000)
packages/linux/nslu2-kernel/2.6.14/50-nslu2-arch.patch
packages/linux/nslu2-kernel_2.6.14.bb

index b502975..7a6dfac 100644 (file)
 +}
 +
 +subsys_initcall(nslu2_pci_init);
---- linux-2.6.13/.pc/50-nslu2-arch.patch/arch/arm/mach-ixp4xx/nslu2-power.c    2005-10-26 15:19:43.171472071 -0700
-+++ linux-2.6.13/arch/arm/mach-ixp4xx/nslu2-power.c    2005-10-26 15:23:39.646352497 -0700
-@@ -0,0 +1,92 @@
+--- linux-2.6.14/arch/arm/mach-ixp4xx/nslu2-power.c    2005-09-06 00:17:15.000000000 -0700
++++ linux-2.6.14/arch/arm/mach-ixp4xx/nslu2-power.c    2005-10-28 15:50:43.554157030 -0700
+@@ -0,0 +1,94 @@
 +/*
 + * arch/arm/mach-ixp4xx/nslu2-power.c
 + *
 +
 +#include <asm/mach-types.h>
 +
++extern void ctrl_alt_del(void);
++
 +static irqreturn_t nslu2_power_handler(int irq, void *dev_id, struct pt_regs *regs)
 +{
-+      /* Signal init to do the ctrlaltdel action */
-+      kill_proc(1, SIGINT, 1);
++      /* Signal init to do the ctrlaltdel action, this will bypass init if
++       * it hasn't started and do a kernel_restart.
++       */
++      ctrl_alt_del();
 +
 +      return IRQ_HANDLED;
 +}
 +
 +static irqreturn_t nslu2_reset_handler(int irq, void *dev_id, struct pt_regs *regs)
 +{
-+      /* FIXME This doesn't reset the NSLU2. It powers it off.
-+       * Close enough, since reset is unreliable
++      /* This is the paper-clip reset, it shuts the machine down directly.
 +       */
-+
 +      machine_power_off();
 +
 +      return IRQ_HANDLED;
 +      .name                   = "IXP4XX-I2C",
 +      .id                     = 0,
 +      .dev.platform_data      = &nslu2_i2c_gpio_pins,
-+      .num_resources          = 0
++      .num_resources          = 0,
 +};
 +
 +static struct resource nslu2_uart_resources[] = {
 +      {
 +              .start          = IXP4XX_UART1_BASE_PHYS,
 +              .end            = IXP4XX_UART1_BASE_PHYS + 0x0fff,
-+              .flags          = IORESOURCE_MEM
++              .flags          = IORESOURCE_MEM,
 +      },
 +      {
 +              .start          = IXP4XX_UART2_BASE_PHYS,
 +              .end            = IXP4XX_UART2_BASE_PHYS + 0x0fff,
-+              .flags          = IORESOURCE_MEM
++              .flags          = IORESOURCE_MEM,
 +      }
 +};
 +
 +      .id                     = PLAT8250_DEV_PLATFORM,
 +      .dev.platform_data      = nslu2_uart_data,
 +      .num_resources          = 2,
-+      .resource               = nslu2_uart_resources
++      .resource               = nslu2_uart_resources,
 +};
 +
 +static struct platform_device *nslu2_devices[] __initdata = {
 +      &nslu2_i2c_controller,
 +      &nslu2_flash,
-+      &nslu2_uart
++      &nslu2_uart,
 +};
 +
 +static void nslu2_power_off(void)
 +{
-+        /* This causes the box to drop the power and go dead. */
++      /* This causes the box to drop the power and go dead. */
 +
 +      /* enable the pwr cntl gpio */
 +      gpio_line_config(NSLU2_PO_GPIO, IXP4XX_GPIO_OUT);
 +      .io_pg_offst    = ((IXP4XX_PERIPHERAL_BASE_VIRT) >> 18) & 0xFFFC,
 +      .boot_params    = 0x00000100,
 +      .map_io         = ixp4xx_map_io,
-+      .init_irq       = ixp4xx_init_irq, /* FIXME: all irq are off here */
-+        .timer          = &ixp4xx_timer,
++      .init_irq       = ixp4xx_init_irq,
++      .timer          = &ixp4xx_timer,
 +      .init_machine   = nslu2_init,
 +MACHINE_END
 --- linux-2.6.13/.pc/50-nslu2-arch.patch/include/asm-arm/arch-ixp4xx/hardware.h        2005-10-26 15:19:37.451112111 -0700
index 21a3713..3dd0778 100644 (file)
@@ -3,7 +3,7 @@
 # Increment PR_CONFIG for changes to the nslu2-kernel specific
 # defconfig (do *NOT* increment anything in here for changes
 # to other kernel configs!)
-PR_CONFIG = "0"
+PR_CONFIG = "1"
 #
 # Increment the number below (i.e. the digits after PR) when
 # making changes within this file or for changes to the patches