Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 15306
b: refs/heads/master
c: 75b245b
h: refs/heads/master
v: v3
  • Loading branch information
Thomas Renninger authored and Len Brown committed Dec 23, 2005
1 parent 5df404e commit 28deeb3
Show file tree
Hide file tree
Showing 28 changed files with 97 additions and 366 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: 3c058d8b179ea3ee3061b71115bcac38d243d436
refs/heads/master: 75b245b3259133360845bc6de3aecb8a6bd6ab59
21 changes: 18 additions & 3 deletions trunk/arch/powerpc/platforms/pseries/xics.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@ static struct hw_interrupt_type xics_pic = {
.set_affinity = xics_set_affinity
};

static struct hw_interrupt_type xics_8259_pic = {
.typename = " XICS/8259",
.ack = xics_mask_and_ack_irq,
};

/* This is used to map real irq numbers to virtual */
static struct radix_tree_root irq_map = RADIX_TREE_INIT(GFP_ATOMIC);

Expand Down Expand Up @@ -362,7 +367,12 @@ int xics_get_irq(struct pt_regs *regs)
/* for sanity, this had better be < NR_IRQS - 16 */
if (vec == xics_irq_8259_cascade_real) {
irq = i8259_irq(regs);
xics_end_irq(irq_offset_up(xics_irq_8259_cascade));
if (irq == -1) {
/* Spurious cascaded interrupt. Still must ack xics */
xics_end_irq(irq_offset_up(xics_irq_8259_cascade));

irq = -1;
}
} else if (vec == XICS_IRQ_SPURIOUS) {
irq = -1;
} else {
Expand Down Expand Up @@ -532,7 +542,6 @@ void xics_init_IRQ(void)
xics_irq_8259_cascade_real = *ireg;
xics_irq_8259_cascade
= virt_irq_create_mapping(xics_irq_8259_cascade_real);
i8259_init(0, 0);
of_node_put(np);
}

Expand All @@ -556,7 +565,12 @@ void xics_init_IRQ(void)
#endif /* CONFIG_SMP */
}

for (i = irq_offset_value(); i < NR_IRQS; ++i)
xics_8259_pic.enable = i8259_pic.enable;
xics_8259_pic.disable = i8259_pic.disable;
xics_8259_pic.end = i8259_pic.end;
for (i = 0; i < 16; ++i)
get_irq_desc(i)->handler = &xics_8259_pic;
for (; i < NR_IRQS; ++i)
get_irq_desc(i)->handler = &xics_pic;

xics_setup_cpu();
Expand All @@ -576,6 +590,7 @@ static int __init xics_setup_i8259(void)
no_action, 0, "8259 cascade", NULL))
printk(KERN_ERR "xics_setup_i8259: couldn't get 8259 "
"cascade\n");
i8259_init(0, 0);
}
return 0;
}
Expand Down
20 changes: 5 additions & 15 deletions trunk/drivers/acpi/processor_idle.c
Original file line number Diff line number Diff line change
Expand Up @@ -274,19 +274,18 @@ static void acpi_processor_idle(void)
}
}

cx->usage++;

#ifdef CONFIG_HOTPLUG_CPU
/*
* Check for P_LVL2_UP flag before entering C2 and above on
* an SMP system. We do it here instead of doing it at _CST/P_LVL
* detection phase, to work cleanly with logical CPU hotplug.
*/
if ((cx->type != ACPI_STATE_C1) && (num_online_cpus() > 1) &&
!pr->flags.has_cst && !acpi_fadt.plvl2_up)
cx = &pr->power.states[ACPI_STATE_C1];
!pr->flags.has_cst && acpi_fadt.plvl2_up)
cx->type = ACPI_STATE_C1;
#endif

cx->usage++;

/*
* Sleep:
* ------
Expand Down Expand Up @@ -387,15 +386,6 @@ static void acpi_processor_idle(void)

next_state = pr->power.state;

#ifdef CONFIG_HOTPLUG_CPU
/* Don't do promotion/demotion */
if ((cx->type == ACPI_STATE_C1) && (num_online_cpus() > 1) &&
!pr->flags.has_cst && !acpi_fadt.plvl2_up) {
next_state = cx;
goto end;
}
#endif

/*
* Promotion?
* ----------
Expand Down Expand Up @@ -567,7 +557,7 @@ static int acpi_processor_get_power_info_fadt(struct acpi_processor *pr)
* Check for P_LVL2_UP flag before entering C2 and above on
* an SMP system.
*/
if ((num_online_cpus() > 1) && !acpi_fadt.plvl2_up)
if ((num_online_cpus() > 1) && acpi_fadt.plvl2_up)
return_VALUE(-ENODEV);
#endif

Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/acpi/processor_thermal.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ static int cpu_has_cpufreq(unsigned int cpu)
{
struct cpufreq_policy policy;
if (!acpi_thermal_cpufreq_is_init || cpufreq_get_policy(&policy, cpu))
return -ENODEV;
return 0;
return 0;
return 1;
}

static int acpi_thermal_cpufreq_increase(unsigned int cpu)
Expand Down
18 changes: 9 additions & 9 deletions trunk/drivers/acpi/utilities/utmisc.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,14 @@ acpi_status acpi_ut_allocate_owner_id(acpi_owner_id * owner_id)

/* Find a free owner ID */

for (i = 0; i < 64; i++) {
if (!(acpi_gbl_owner_id_mask & (1ULL << i))) {
for (i = 0; i < 32; i++) {
if (!(acpi_gbl_owner_id_mask & (1 << i))) {
ACPI_DEBUG_PRINT((ACPI_DB_VALUES,
"Current owner_id mask: %16.16LX New ID: %2.2X\n",
"Current owner_id mask: %8.8X New ID: %2.2X\n",
acpi_gbl_owner_id_mask,
(unsigned int)(i + 1)));

acpi_gbl_owner_id_mask |= (1ULL << i);
acpi_gbl_owner_id_mask |= (1 << i);
*owner_id = (acpi_owner_id) (i + 1);
goto exit;
}
Expand All @@ -106,7 +106,7 @@ acpi_status acpi_ut_allocate_owner_id(acpi_owner_id * owner_id)
*/
*owner_id = 0;
status = AE_OWNER_ID_LIMIT;
ACPI_REPORT_ERROR(("Could not allocate new owner_id (64 max), AE_OWNER_ID_LIMIT\n"));
ACPI_REPORT_ERROR(("Could not allocate new owner_id (32 max), AE_OWNER_ID_LIMIT\n"));

exit:
(void)acpi_ut_release_mutex(ACPI_MTX_CACHES);
Expand All @@ -123,7 +123,7 @@ acpi_status acpi_ut_allocate_owner_id(acpi_owner_id * owner_id)
* control method or unloading a table. Either way, we would
* ignore any error anyway.
*
* DESCRIPTION: Release a table or method owner ID. Valid IDs are 1 - 64
* DESCRIPTION: Release a table or method owner ID. Valid IDs are 1 - 32
*
******************************************************************************/

Expand All @@ -140,7 +140,7 @@ void acpi_ut_release_owner_id(acpi_owner_id * owner_id_ptr)

/* Zero is not a valid owner_iD */

if ((owner_id == 0) || (owner_id > 64)) {
if ((owner_id == 0) || (owner_id > 32)) {
ACPI_REPORT_ERROR(("Invalid owner_id: %2.2X\n", owner_id));
return_VOID;
}
Expand All @@ -158,8 +158,8 @@ void acpi_ut_release_owner_id(acpi_owner_id * owner_id_ptr)

/* Free the owner ID only if it is valid */

if (acpi_gbl_owner_id_mask & (1ULL << owner_id)) {
acpi_gbl_owner_id_mask ^= (1ULL << owner_id);
if (acpi_gbl_owner_id_mask & (1 << owner_id)) {
acpi_gbl_owner_id_mask ^= (1 << owner_id);
}

(void)acpi_ut_release_mutex(ACPI_MTX_CACHES);
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/media/video/saa7127.c
Original file line number Diff line number Diff line change
Expand Up @@ -389,15 +389,15 @@ static int saa7127_set_vps(struct i2c_client *client, struct v4l2_sliced_vbi_dat
static int saa7127_set_cc(struct i2c_client *client, struct v4l2_sliced_vbi_data *data)
{
struct saa7127_state *state = i2c_get_clientdata(client);
u16 cc = data->data[1] << 8 | data->data[0];
u16 cc = data->data[0] << 8 | data->data[1];
int enable = (data->line != 0);

if (enable && (data->field != 0 || data->line != 21))
return -EINVAL;
if (state->cc_enable != enable) {
saa7127_dbg("Turn CC %s\n", enable ? "on" : "off");
saa7127_write(client, SAA7127_REG_CLOSED_CAPTION,
(state->xds_enable << 7) | (enable << 6) | 0x11);
(enable << 6) | 0x11);
state->cc_enable = enable;
}
if (!enable)
Expand All @@ -423,7 +423,7 @@ static int saa7127_set_xds(struct i2c_client *client, struct v4l2_sliced_vbi_dat
if (state->xds_enable != enable) {
saa7127_dbg("Turn XDS %s\n", enable ? "on" : "off");
saa7127_write(client, SAA7127_REG_CLOSED_CAPTION,
(enable << 7) | (state->cc_enable << 6) | 0x11);
(enable << 7) | 0x11);
state->xds_enable = enable;
}
if (!enable)
Expand Down
26 changes: 2 additions & 24 deletions trunk/drivers/media/video/saa7134/Kconfig
Original file line number Diff line number Diff line change
@@ -1,40 +1,18 @@
config VIDEO_SAA7134
tristate "Philips SAA7134 support"
depends on VIDEO_DEV && PCI && I2C
depends on VIDEO_DEV && PCI && I2C && SOUND && SND
select VIDEO_BUF
select VIDEO_IR
select VIDEO_TUNER
select CRC32
select SND_PCM_OSS
---help---
This is a video4linux driver for Philips SAA713x based
TV cards.

To compile this driver as a module, choose M here: the
module will be called saa7134.

config VIDEO_SAA7134_ALSA
tristate "Philips SAA7134 DMA audio support"
depends on VIDEO_SAA7134 && SOUND && SND && (!VIDEO_SAA7134_OSS || VIDEO_SAA7134_OSS = m)
select SND_PCM_OSS
---help---
This is a video4linux driver for direct (DMA) audio in
Philips SAA713x based TV cards using ALSA

To compile this driver as a module, choose M here: the
module will be called saa7134-alsa.

config VIDEO_SAA7134_OSS
tristate "Philips SAA7134 DMA audio support (OSS, DEPRECATED)"
depends on VIDEO_SAA7134 && SOUND_PRIME && (!VIDEO_SAA7134_ALSA || VIDEO_SAA7134_ALSA = m)
---help---
This is a video4linux driver for direct (DMA) audio in
Philips SAA713x based TV cards using OSS

This is deprecated in favor of the ALSA module

To compile this driver as a module, choose M here: the
module will be called saa7134-oss.

config VIDEO_SAA7134_DVB
tristate "DVB/ATSC Support for saa7134 based TV cards"
depends on VIDEO_SAA7134 && DVB_CORE
Expand Down
7 changes: 2 additions & 5 deletions trunk/drivers/media/video/saa7134/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,8 @@ saa7134-objs := saa7134-cards.o saa7134-core.o saa7134-i2c.o \
saa7134-video.o saa7134-input.o

obj-$(CONFIG_VIDEO_SAA7134) += saa7134.o saa7134-empress.o \
saa6752hs.o

obj-$(CONFIG_VIDEO_SAA7134_ALSA) += saa7134-alsa.o
obj-$(CONFIG_VIDEO_SAA7134_OSS) += saa7134-oss.o

saa6752hs.o saa7134-alsa.o \
saa7134-oss.o
obj-$(CONFIG_VIDEO_SAA7134_DVB) += saa7134-dvb.o

EXTRA_CFLAGS += -I$(src)/..
Expand Down
16 changes: 4 additions & 12 deletions trunk/drivers/media/video/saa7134/saa7134-alsa.c
Original file line number Diff line number Diff line change
Expand Up @@ -989,14 +989,6 @@ static int saa7134_alsa_init(void)
struct saa7134_dev *dev = NULL;
struct list_head *list;

if (!dmasound_init && !dmasound_exit) {
dmasound_init = alsa_device_init;
dmasound_exit = alsa_device_exit;
} else {
printk(KERN_WARNING "saa7134 ALSA: can't load, DMA sound handler already assigned (probably to OSS)\n");
return -EBUSY;
}

printk(KERN_INFO "saa7134 ALSA driver for DMA sound loaded\n");

list_for_each(list,&saa7134_devlist) {
Expand All @@ -1009,6 +1001,9 @@ static int saa7134_alsa_init(void)
}
}

dmasound_init = alsa_device_init;
dmasound_exit = alsa_device_exit;

if (dev == NULL)
printk(KERN_INFO "saa7134 ALSA: no saa7134 cards found\n");

Expand All @@ -1028,15 +1023,12 @@ static void saa7134_alsa_exit(void)
snd_card_free(snd_saa7134_cards[idx]);
}

dmasound_init = NULL;
dmasound_exit = NULL;
printk(KERN_INFO "saa7134 ALSA driver for DMA sound unloaded\n");

return;
}

/* We initialize this late, to make sure the sound system is up and running */
late_initcall(saa7134_alsa_init);
module_init(saa7134_alsa_init);
module_exit(saa7134_alsa_exit);
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Ricardo Cerqueira");
Expand Down
18 changes: 4 additions & 14 deletions trunk/drivers/media/video/saa7134/saa7134-oss.c
Original file line number Diff line number Diff line change
Expand Up @@ -959,17 +959,8 @@ static int saa7134_oss_init(void)
struct saa7134_dev *dev = NULL;
struct list_head *list;

if (!dmasound_init && !dmasound_exit) {
dmasound_init = oss_device_init;
dmasound_exit = oss_device_exit;
} else {
printk(KERN_WARNING "saa7134 OSS: can't load, DMA sound handler already assigned (probably to ALSA)\n");
return -EBUSY;
}

printk(KERN_INFO "saa7134 OSS driver for DMA sound loaded\n");


list_for_each(list,&saa7134_devlist) {
dev = list_entry(list, struct saa7134_dev, devlist);
if (dev->dmasound.priv_data == NULL) {
Expand All @@ -983,6 +974,9 @@ static int saa7134_oss_init(void)
if (dev == NULL)
printk(KERN_INFO "saa7134 OSS: no saa7134 cards found\n");

dmasound_init = oss_device_init;
dmasound_exit = oss_device_exit;

return 0;

}
Expand All @@ -1003,16 +997,12 @@ static void saa7134_oss_exit(void)

}

dmasound_init = NULL;
dmasound_exit = NULL;

printk(KERN_INFO "saa7134 OSS driver for DMA sound unloaded\n");

return;
}

/* We initialize this late, to make sure the sound system is up and running */
late_initcall(saa7134_oss_init);
module_init(saa7134_oss_init);
module_exit(saa7134_oss_exit);
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Gerd Knorr <kraxel@bytesex.org> [SuSE Labs]");
Expand Down
Loading

0 comments on commit 28deeb3

Please sign in to comment.