Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 4867
b: refs/heads/master
c: c1c58ad
h: refs/heads/master
i:
  4865: 186b4ec
  4863: ded1aa4
v: v3
  • Loading branch information
Anton Altaparmakov committed May 25, 2005
1 parent e465d24 commit dabba71
Show file tree
Hide file tree
Showing 29 changed files with 186 additions and 93 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 67394f8f069c2fdf90f3b6d851824c07815442af
refs/heads/master: c1c58ada91cfe86f19d430282132434e620a1067
2 changes: 1 addition & 1 deletion trunk/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION = 2
PATCHLEVEL = 6
SUBLEVEL = 12
EXTRAVERSION =-rc4
EXTRAVERSION =-rc5
NAME=Woozy Numbat

# *DOCUMENTATION*
Expand Down
17 changes: 8 additions & 9 deletions trunk/arch/i386/mach-voyager/voyager_smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ static void ack_vic_irq(unsigned int irq);
static void vic_enable_cpi(void);
static void do_boot_cpu(__u8 cpuid);
static void do_quad_bootstrap(void);
static inline void wrapper_smp_local_timer_interrupt(struct pt_regs *);

int hard_smp_processor_id(void);

Expand Down Expand Up @@ -125,6 +124,14 @@ send_QIC_CPI(__u32 cpuset, __u8 cpi)
}
}

static inline void
wrapper_smp_local_timer_interrupt(struct pt_regs *regs)
{
irq_enter();
smp_local_timer_interrupt(regs);
irq_exit();
}

static inline void
send_one_CPI(__u8 cpu, __u8 cpi)
{
Expand Down Expand Up @@ -1249,14 +1256,6 @@ smp_vic_timer_interrupt(struct pt_regs *regs)
smp_local_timer_interrupt(regs);
}

static inline void
wrapper_smp_local_timer_interrupt(struct pt_regs *regs)
{
irq_enter();
smp_local_timer_interrupt(regs);
irq_exit();
}

/* local (per CPU) timer interrupt. It does both profiling and
* process statistics/rescheduling.
*
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/ppc/syslib/ipic.c
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ void __init ipic_init(phys_addr_t phys_addr,
temp = 0;
for (i = 0 ; i < senses_count ; i++) {
if ((senses[i] & IRQ_SENSE_MASK) == IRQ_SENSE_EDGE) {
temp |= 1 << (16 - i);
temp |= 1 << (15 - i);
if (i != 0)
irq_desc[i + irq_offset + MPC83xx_IRQ_EXT1 - 1].status = 0;
else
Expand Down
28 changes: 21 additions & 7 deletions trunk/arch/ppc64/kernel/pmac_smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ extern struct smp_ops_t *smp_ops;

static void (*pmac_tb_freeze)(int freeze);
static struct device_node *pmac_tb_clock_chip_host;
static u8 pmac_tb_pulsar_addr;
static DEFINE_SPINLOCK(timebase_lock);
static unsigned long timebase;

Expand Down Expand Up @@ -106,12 +107,9 @@ static void smp_core99_pulsar_tb_freeze(int freeze)
u8 data;
int rc;

/* Strangely, the device-tree says address is 0xd2, but darwin
* accesses 0xd0 ...
*/
pmac_low_i2c_setmode(pmac_tb_clock_chip_host, pmac_low_i2c_mode_combined);
rc = pmac_low_i2c_xfer(pmac_tb_clock_chip_host,
0xd4 | pmac_low_i2c_read,
pmac_tb_pulsar_addr | pmac_low_i2c_read,
0x2e, &data, 1);
if (rc != 0)
goto bail;
Expand All @@ -120,7 +118,7 @@ static void smp_core99_pulsar_tb_freeze(int freeze)

pmac_low_i2c_setmode(pmac_tb_clock_chip_host, pmac_low_i2c_mode_stdsub);
rc = pmac_low_i2c_xfer(pmac_tb_clock_chip_host,
0xd4 | pmac_low_i2c_write,
pmac_tb_pulsar_addr | pmac_low_i2c_write,
0x2e, &data, 1);
bail:
if (rc != 0) {
Expand Down Expand Up @@ -185,6 +183,12 @@ static int __init smp_core99_probe(void)
if (ncpus <= 1)
return 1;

/* HW sync only on these platforms */
if (!machine_is_compatible("PowerMac7,2") &&
!machine_is_compatible("PowerMac7,3") &&
!machine_is_compatible("RackMac3,1"))
goto nohwsync;

/* Look for the clock chip */
for (cc = NULL; (cc = of_find_node_by_name(cc, "i2c-hwclock")) != NULL;) {
struct device_node *p = of_get_parent(cc);
Expand All @@ -198,24 +202,34 @@ static int __init smp_core99_probe(void)
goto next;
switch (*reg) {
case 0xd2:
pmac_tb_freeze = smp_core99_cypress_tb_freeze;
printk(KERN_INFO "Timebase clock is Cypress chip\n");
if (device_is_compatible(cc, "pulsar-legacy-slewing")) {
pmac_tb_freeze = smp_core99_pulsar_tb_freeze;
pmac_tb_pulsar_addr = 0xd2;
printk(KERN_INFO "Timebase clock is Pulsar chip\n");
} else if (device_is_compatible(cc, "cy28508")) {
pmac_tb_freeze = smp_core99_cypress_tb_freeze;
printk(KERN_INFO "Timebase clock is Cypress chip\n");
}
break;
case 0xd4:
pmac_tb_freeze = smp_core99_pulsar_tb_freeze;
pmac_tb_pulsar_addr = 0xd4;
printk(KERN_INFO "Timebase clock is Pulsar chip\n");
break;
}
if (pmac_tb_freeze != NULL) {
pmac_tb_clock_chip_host = p;
smp_ops->give_timebase = smp_core99_give_timebase;
smp_ops->take_timebase = smp_core99_take_timebase;
of_node_put(cc);
of_node_put(p);
break;
}
next:
of_node_put(p);
}

nohwsync:
mpic_request_ipis();

return ncpus;
Expand Down
44 changes: 43 additions & 1 deletion trunk/arch/ppc64/kernel/prom_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -1750,7 +1750,44 @@ static void __init flatten_device_tree(void)
prom_printf("Device tree struct 0x%x -> 0x%x\n",
RELOC(dt_struct_start), RELOC(dt_struct_end));

}
}


static void __init fixup_device_tree(void)
{
unsigned long offset = reloc_offset();
phandle u3, i2c, mpic;
u32 u3_rev;
u32 interrupts[2];
u32 parent;

/* Some G5s have a missing interrupt definition, fix it up here */
u3 = call_prom("finddevice", 1, 1, ADDR("/u3@0,f8000000"));
if ((long)u3 <= 0)
return;
i2c = call_prom("finddevice", 1, 1, ADDR("/u3@0,f8000000/i2c@f8001000"));
if ((long)i2c <= 0)
return;
mpic = call_prom("finddevice", 1, 1, ADDR("/u3@0,f8000000/mpic@f8040000"));
if ((long)mpic <= 0)
return;

/* check if proper rev of u3 */
if (prom_getprop(u3, "device-rev", &u3_rev, sizeof(u3_rev)) <= 0)
return;
if (u3_rev != 0x35)
return;
/* does it need fixup ? */
if (prom_getproplen(i2c, "interrupts") > 0)
return;
/* interrupt on this revision of u3 is number 0 and level */
interrupts[0] = 0;
interrupts[1] = 1;
prom_setprop(i2c, "interrupts", &interrupts, sizeof(interrupts));
parent = (u32)mpic;
prom_setprop(i2c, "interrupt-parent", &parent, sizeof(parent));
}


static void __init prom_find_boot_cpu(void)
{
Expand Down Expand Up @@ -1919,6 +1956,11 @@ unsigned long __init prom_init(unsigned long r3, unsigned long r4, unsigned long
PTRRELOC(&prom_tce_alloc_end), sizeof(RELOC(prom_tce_alloc_end)));
}

/*
* Fixup any known bugs in the device-tree
*/
fixup_device_tree();

/*
* Now finally create the flattened device-tree
*/
Expand Down
2 changes: 1 addition & 1 deletion trunk/crypto/internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ static inline void crypto_kunmap(void *vaddr, int out)

static inline void crypto_yield(struct crypto_tfm *tfm)
{
if (!in_softirq())
if (!in_atomic())
cond_resched();
}

Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/base/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@ int device_add(struct device *dev)

if ((error = kobject_add(&dev->kobj)))
goto Error;
kobject_hotplug(&dev->kobj, KOBJ_ADD);
if ((error = device_pm_add(dev)))
goto PMError;
if ((error = bus_add_device(dev)))
Expand All @@ -257,14 +258,13 @@ int device_add(struct device *dev)
/* notify platform of device entry */
if (platform_notify)
platform_notify(dev);

kobject_hotplug(&dev->kobj, KOBJ_ADD);
Done:
put_device(dev);
return error;
BusError:
device_pm_remove(dev);
PMError:
kobject_hotplug(&dev->kobj, KOBJ_REMOVE);
kobject_del(&dev->kobj);
Error:
if (parent)
Expand Down
5 changes: 5 additions & 0 deletions trunk/drivers/i2c/busses/i2c-keywest.c
Original file line number Diff line number Diff line change
Expand Up @@ -516,6 +516,11 @@ create_iface(struct device_node *np, struct device *dev)
u32 *psteps, *prate;
int rc;

if (np->n_intrs < 1 || np->n_addrs < 1) {
printk(KERN_ERR "%s: Missing interrupt or address !\n",
np->full_name);
return -ENODEV;
}
if (pmac_low_i2c_lock(np))
return -ENODEV;

Expand Down
10 changes: 5 additions & 5 deletions trunk/drivers/media/video/saa7134/saa6752hs.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@ enum saa6752hs_videoformat {
static const struct v4l2_format v4l2_format_table[] =
{
[SAA6752HS_VF_D1] = {
.fmt.pix.width = 720, .fmt.pix.height = 576 },
.fmt = { .pix = { .width = 720, .height = 576 }, }, },
[SAA6752HS_VF_2_3_D1] = {
.fmt.pix.width = 480, .fmt.pix.height = 576 },
.fmt = { .pix = { .width = 480, .height = 576 }, }, },
[SAA6752HS_VF_1_2_D1] = {
.fmt.pix.width = 352, .fmt.pix.height = 576 },
.fmt = { .pix = { .width = 352, .height = 576 }, }, },
[SAA6752HS_VF_SIF] = {
.fmt.pix.width = 352, .fmt.pix.height = 288 },
.fmt = { .pix = { .width = 352, .height = 288 }, }, },
[SAA6752HS_VF_UNKNOWN] = {
.fmt.pix.width = 0, .fmt.pix.height = 0},
.fmt = { .pix = { .width = 0, .height = 0 }, }, },
};

struct saa6752hs_state {
Expand Down
5 changes: 4 additions & 1 deletion trunk/drivers/mmc/mmc_block.c
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,10 @@ static int mmc_blk_probe(struct mmc_card *card)
struct mmc_blk_data *md;
int err;

if (card->csd.cmdclass & ~0x1ff)
/*
* Check that the card supports the command class(es) we need.
*/
if (!(card->csd.cmdclass & CCC_BLOCK_READ))
return -ENODEV;

if (card->csd.read_blkbits < 9) {
Expand Down
8 changes: 5 additions & 3 deletions trunk/drivers/net/tg3.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@

#define DRV_MODULE_NAME "tg3"
#define PFX DRV_MODULE_NAME ": "
#define DRV_MODULE_VERSION "3.27"
#define DRV_MODULE_RELDATE "May 5, 2005"
#define DRV_MODULE_VERSION "3.29"
#define DRV_MODULE_RELDATE "May 23, 2005"

#define TG3_DEF_MAC_MODE 0
#define TG3_DEF_RX_MODE 0
Expand Down Expand Up @@ -206,6 +206,8 @@ static struct pci_device_id tg3_pci_tbl[] = {
PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0UL },
{ PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5752,
PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0UL },
{ PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5752M,
PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0UL },
{ PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5753,
PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0UL },
{ PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5753M,
Expand Down Expand Up @@ -8994,7 +8996,7 @@ static int __devinit tg3_do_test_dma(struct tg3 *tp, u32 *buf, dma_addr_t buf_dm
return ret;
}

#define TEST_BUFFER_SIZE 0x400
#define TEST_BUFFER_SIZE 0x2000

static int __devinit tg3_test_dma(struct tg3 *tp)
{
Expand Down
7 changes: 5 additions & 2 deletions trunk/drivers/scsi/aic7xxx/aic7xxx_osm.c
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,11 @@ ahc_linux_slave_alloc(struct scsi_device *device)
ahc_lock(ahc, &flags);
targ = ahc->platform_data->targets[target_offset];
if (targ == NULL) {
targ = ahc_linux_alloc_target(ahc, starget->channel, starget->id);
struct seeprom_config *sc = ahc->seep_config;
struct seeprom_config *sc;

targ = ahc_linux_alloc_target(ahc, starget->channel,
starget->id);
sc = ahc->seep_config;
if (targ == NULL)
goto out;

Expand Down
17 changes: 12 additions & 5 deletions trunk/drivers/serial/8250.c
Original file line number Diff line number Diff line change
Expand Up @@ -682,8 +682,6 @@ static void autoconfig_16550a(struct uart_8250_port *up)
* from EXCR1. Switch back to bank 0, change it in MCR. Then
* switch back to bank 2, read it from EXCR1 again and check
* it's changed. If so, set baud_base in EXCR2 to 921600. -- dwmw2
* On PowerPC we don't want to change baud_base, as we have
* a number of different divisors. -- Tom Rini
*/
serial_outp(up, UART_LCR, 0);
status1 = serial_in(up, UART_MCR);
Expand All @@ -699,16 +697,25 @@ static void autoconfig_16550a(struct uart_8250_port *up)
serial_outp(up, UART_MCR, status1);

if ((status2 ^ status1) & UART_MCR_LOOP) {
#ifndef CONFIG_PPC
unsigned short quot;

serial_outp(up, UART_LCR, 0xE0);

quot = serial_inp(up, UART_DLM) << 8;
quot += serial_inp(up, UART_DLL);
quot <<= 3;

status1 = serial_in(up, 0x04); /* EXCR1 */
status1 &= ~0xB0; /* Disable LOCK, mask out PRESL[01] */
status1 |= 0x10; /* 1.625 divisor for baud_base --> 921600 */
serial_outp(up, 0x04, status1);

serial_outp(up, UART_DLL, quot & 0xff);
serial_outp(up, UART_DLM, quot >> 8);

serial_outp(up, UART_LCR, 0);
up->port.uartclk = 921600*16;
#endif

up->port.uartclk = 921600*16;
up->port.type = PORT_NS16550A;
up->capabilities |= UART_NATSEMI;
return;
Expand Down
1 change: 0 additions & 1 deletion trunk/fs/reiserfs/stree.c
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,6 @@ const struct reiserfs_key MAX_KEY = {
__constant_cpu_to_le32(0xffffffff)},}
};

const struct in_core_key MAX_IN_CORE_KEY = {~0U, ~0U, ~0ULL>>4, 15};

/* Get delimiting key of the buffer by looking for it in the buffers in the path, starting from the bottom
of the path, and going upwards. We must check the path's validity at each step. If the key is not in
Expand Down
4 changes: 3 additions & 1 deletion trunk/fs/reiserfs/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,9 @@ static int finish_unfinished (struct super_block * s)

/* compose key to look for "save" links */
max_cpu_key.version = KEY_FORMAT_3_5;
max_cpu_key.on_disk_key = MAX_IN_CORE_KEY;
max_cpu_key.on_disk_key.k_dir_id = ~0U;
max_cpu_key.on_disk_key.k_objectid = ~0U;
set_cpu_key_k_offset (&max_cpu_key, ~0U);
max_cpu_key.key_length = 3;

#ifdef CONFIG_QUOTA
Expand Down
Loading

0 comments on commit dabba71

Please sign in to comment.