Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 56821
b: refs/heads/master
c: 5ac43d1
h: refs/heads/master
i:
  56819: be80c20
v: v3
  • Loading branch information
Oliver Neukum authored and Greg Kroah-Hartman committed May 23, 2007
1 parent 7763927 commit 51d1ed4
Show file tree
Hide file tree
Showing 13 changed files with 60 additions and 69 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: 31f6e1bd3b58c9a67e5ea0c2d372fbf5fc9e326d
refs/heads/master: 5ac43d1fbbfd1b89f83c1a907c58d558d262e441
4 changes: 3 additions & 1 deletion trunk/drivers/input/joystick/iforce/iforce-main.c
Original file line number Diff line number Diff line change
Expand Up @@ -370,8 +370,10 @@ int iforce_init_device(struct iforce *iforce)

/*
* Disable spring, enable force feedback.
* FIXME: We should use iforce_set_autocenter() et al here.
*/
iforce_set_autocenter(input_dev, 0);

iforce_send_packet(iforce, FF_CMD_AUTOCENTER, "\004\000");

/*
* Find appropriate device entry
Expand Down
10 changes: 2 additions & 8 deletions trunk/drivers/input/joystick/iforce/iforce-packets.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,6 @@ void iforce_process_packet(struct iforce *iforce, u16 cmd, unsigned char *data)

int iforce_get_id_packet(struct iforce *iforce, char *packet)
{
int status;

switch (iforce->bus) {

case IFORCE_USB:
Expand All @@ -256,22 +254,18 @@ int iforce_get_id_packet(struct iforce *iforce, char *packet)
iforce->cr.bRequest = packet[0];
iforce->ctrl->dev = iforce->usbdev;

status = usb_submit_urb(iforce->ctrl, GFP_ATOMIC);
if (status) {
err("usb_submit_urb failed %d", status);
if (usb_submit_urb(iforce->ctrl, GFP_ATOMIC))
return -1;
}

wait_event_interruptible_timeout(iforce->wait,
iforce->ctrl->status != -EINPROGRESS, HZ);

if (iforce->ctrl->status) {
dbg("iforce->ctrl->status = %d", iforce->ctrl->status);
usb_unlink_urb(iforce->ctrl);
return -1;
}
#else
dbg("iforce_get_id_packet: iforce->bus = USB!");
err("iforce_get_id_packet: iforce->bus = USB!");
#endif
break;

Expand Down
5 changes: 2 additions & 3 deletions trunk/drivers/input/joystick/iforce/iforce-usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ void iforce_usb_xmit(struct iforce *iforce)
XMIT_INC(iforce->xmit.tail, n);

if ( (n=usb_submit_urb(iforce->out, GFP_ATOMIC)) ) {
clear_bit(IFORCE_XMIT_RUNNING, iforce->xmit_flags);
warn("usb_submit_urb failed %d\n", n);
}

Expand Down Expand Up @@ -164,8 +163,8 @@ static int iforce_usb_probe(struct usb_interface *intf,
usb_fill_int_urb(iforce->irq, dev, usb_rcvintpipe(dev, epirq->bEndpointAddress),
iforce->data, 16, iforce_usb_irq, iforce, epirq->bInterval);

usb_fill_int_urb(iforce->out, dev, usb_sndintpipe(dev, epout->bEndpointAddress),
iforce + 1, 32, iforce_usb_out, iforce, epout->bInterval);
usb_fill_bulk_urb(iforce->out, dev, usb_sndbulkpipe(dev, epout->bEndpointAddress),
iforce + 1, 32, iforce_usb_out, iforce);

usb_fill_control_urb(iforce->ctrl, dev, usb_rcvctrlpipe(dev, 0),
(void*) &iforce->cr, iforce->edata, 16, iforce_usb_ctrl, iforce);
Expand Down
5 changes: 0 additions & 5 deletions trunk/drivers/input/misc/input-polldev.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,6 @@
#include <linux/mutex.h>
#include <linux/input-polldev.h>

MODULE_AUTHOR("Dmitry Torokhov <dtor@mail.ru>");
MODULE_DESCRIPTION("Generic implementation of a polled input device");
MODULE_LICENSE("GPL v2");
MODULE_VERSION("0.1");

static DEFINE_MUTEX(polldev_mutex);
static int polldev_users;
static struct workqueue_struct *polldev_wq;
Expand Down
58 changes: 27 additions & 31 deletions trunk/drivers/input/mouse/alps.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,15 +251,11 @@ static const struct alps_model_info *alps_get_model(struct psmouse *psmouse, int

dbg("E7 report: %2.2x %2.2x %2.2x", param[0], param[1], param[2]);

if (version) {
for (i = 0; i < ARRAY_SIZE(rates) && param[2] != rates[i]; i++)
/* empty */;
*version = (param[0] << 8) | (param[1] << 4) | i;
}
for (i = 0; i < ARRAY_SIZE(rates) && param[2] != rates[i]; i++);
*version = (param[0] << 8) | (param[1] << 4) | i;

for (i = 0; i < ARRAY_SIZE(alps_model_data); i++)
if (!memcmp(param, alps_model_data[i].signature,
sizeof(alps_model_data[i].signature)))
if (!memcmp(param, alps_model_data[i].signature, sizeof(alps_model_data[i].signature)))
return alps_model_data + i;

return NULL;
Expand Down Expand Up @@ -384,46 +380,32 @@ static int alps_poll(struct psmouse *psmouse)
return 0;
}

static int alps_hw_init(struct psmouse *psmouse, int *version)
static int alps_reconnect(struct psmouse *psmouse)
{
struct alps_data *priv = psmouse->private;
int version;

priv->i = alps_get_model(psmouse, version);
if (!priv->i)
psmouse_reset(psmouse);

if (!(priv->i = alps_get_model(psmouse, &version)))
return -1;

if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 1))
return -1;

if (alps_tap_mode(psmouse, 1)) {
printk(KERN_WARNING "alps.c: Failed to enable hardware tapping\n");
printk(KERN_WARNING "alps.c: Failed to reenable hardware tapping\n");
return -1;
}

if (alps_absolute_mode(psmouse)) {
printk(KERN_ERR "alps.c: Failed to enable absolute mode\n");
printk(KERN_ERR "alps.c: Failed to reenable absolute mode\n");
return -1;
}

if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 0))
return -1;

/* ALPS needs stream mode, otherwise it won't report any data */
if (ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_SETSTREAM)) {
printk(KERN_ERR "alps.c: Failed to enable stream mode\n");
return -1;
}

return 0;
}

static int alps_reconnect(struct psmouse *psmouse)
{
psmouse_reset(psmouse);

if (alps_hw_init(psmouse, NULL))
return -1;

return 0;
}

Expand All @@ -448,9 +430,23 @@ int alps_init(struct psmouse *psmouse)
goto init_fail;

priv->dev2 = dev2;
psmouse->private = priv;

if (alps_hw_init(psmouse, &version))
priv->i = alps_get_model(psmouse, &version);
if (!priv->i)
goto init_fail;

if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 1))
goto init_fail;

if (alps_tap_mode(psmouse, 1))
printk(KERN_WARNING "alps.c: Failed to enable hardware tapping\n");

if (alps_absolute_mode(psmouse)) {
printk(KERN_ERR "alps.c: Failed to enable absolute mode\n");
goto init_fail;
}

if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 0))
goto init_fail;

dev1->evbit[LONG(EV_KEY)] |= BIT(EV_KEY);
Expand Down Expand Up @@ -497,13 +493,13 @@ int alps_init(struct psmouse *psmouse)
/* We are having trouble resyncing ALPS touchpads so disable it for now */
psmouse->resync_time = 0;

psmouse->private = priv;
return 0;

init_fail:
psmouse_reset(psmouse);
input_free_device(dev2);
kfree(priv);
psmouse->private = NULL;
return -1;
}

Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/input/mouse/logips2pp.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,6 @@ static const struct ps2pp_info *get_model_info(unsigned char model)
{ 66, PS2PP_KIND_MX, /* MX3100 reciver */
PS2PP_WHEEL | PS2PP_SIDE_BTN | PS2PP_TASK_BTN |
PS2PP_EXTRA_BTN | PS2PP_NAV_BTN | PS2PP_HWHEEL },
{ 72, PS2PP_KIND_TRACKMAN, 0 }, /* T-CH11: TrackMan Marble */
{ 73, 0, PS2PP_SIDE_BTN },
{ 75, PS2PP_KIND_WHEEL, PS2PP_WHEEL },
{ 76, PS2PP_KIND_WHEEL, PS2PP_WHEEL },
Expand Down
8 changes: 4 additions & 4 deletions trunk/drivers/input/touchscreen/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,17 @@ menuconfig INPUT_TOUCHSCREEN
if INPUT_TOUCHSCREEN

config TOUCHSCREEN_ADS7846
tristate "ADS7846/TSC2046 and ADS7843 based touchscreens"
tristate "ADS 7846/7843 based touchscreens"
depends on SPI_MASTER
depends on HWMON = n || HWMON
help
Say Y here if you have a touchscreen interface using the
ADS7846/TSC2046 or ADS7843 controller, and your board-specific
setup code includes that in its table of SPI devices.
ADS7846 or ADS7843 controller, and your board-specific setup
code includes that in its table of SPI devices.

If HWMON is selected, and the driver is told the reference voltage
on your board, you will also get hwmon interfaces for the voltage
(and on ads7846/tsc2046, temperature) sensors of this chip.
(and on ads7846, temperature) sensors of this chip.

If unsure, say N (but it's safe to say "Y").

Expand Down
3 changes: 1 addition & 2 deletions trunk/drivers/input/touchscreen/ads7846.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
/*
* This code has been heavily tested on a Nokia 770, and lightly
* tested on other ads7846 devices (OSK/Mistral, Lubbock).
* TSC2046 is just newer ads7846 silicon.
* Support for ads7843 tested on Atmel at91sam926x-EK.
* Support for ads7845 has only been stubbed in.
*
Expand Down Expand Up @@ -848,7 +847,7 @@ static int __devinit ads7846_probe(struct spi_device *spi)
* may not. So we stick to very-portable 8 bit words, both RX and TX.
*/
spi->bits_per_word = 8;
spi->mode = SPI_MODE_0;
spi->mode = SPI_MODE_1;
err = spi_setup(spi);
if (err < 0)
return err;
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/input/touchscreen/ucb1400_ts.c
Original file line number Diff line number Diff line change
Expand Up @@ -288,9 +288,9 @@ static int ucb1400_ts_thread(void *_ucb)
struct ucb1400 *ucb = _ucb;
struct task_struct *tsk = current;
int valid = 0;
struct sched_param param = { .sched_priority = 1 };

sched_setscheduler(tsk, SCHED_FIFO, &param);
tsk->policy = SCHED_FIFO;
tsk->rt_priority = 1;

while (!kthread_should_stop()) {
unsigned int x, y, p;
Expand Down
16 changes: 8 additions & 8 deletions trunk/drivers/macintosh/adbhid.c
Original file line number Diff line number Diff line change
Expand Up @@ -628,16 +628,16 @@ static void real_leds(unsigned char leds, int device)
*/
static int adbhid_kbd_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
{
struct adbhid *adbhid = input_get_drvdata(dev);
struct adbhid *adbhid = dev->private;
unsigned char leds;

switch (type) {
case EV_LED:
leds = (test_bit(LED_SCROLLL, dev->led) ? 4 : 0) |
(test_bit(LED_NUML, dev->led) ? 1 : 0) |
(test_bit(LED_CAPSL, dev->led) ? 2 : 0);
real_leds(leds, adbhid->id);
return 0;
leds = (test_bit(LED_SCROLLL, dev->led) ? 4 : 0)
| (test_bit(LED_NUML, dev->led) ? 1 : 0)
| (test_bit(LED_CAPSL, dev->led) ? 2 : 0);
real_leds(leds, adbhid->id);
return 0;
}

return -1;
Expand All @@ -649,7 +649,7 @@ adb_message_handler(struct notifier_block *this, unsigned long code, void *x)
switch (code) {
case ADB_MSG_PRE_RESET:
case ADB_MSG_POWERDOWN:
/* Stop the repeat timer. Autopoll is already off at this point */
/* Stop the repeat timer. Autopoll is already off at this point */
{
int i;
for (i = 1; i < 16; i++) {
Expand Down Expand Up @@ -699,7 +699,7 @@ adbhid_input_register(int id, int default_id, int original_handler_id,
hid->current_handler_id = current_handler_id;
hid->mouse_kind = mouse_kind;
hid->flags = 0;
input_set_drvdata(input_dev, hid);
input_dev->private = hid;
input_dev->name = hid->name;
input_dev->phys = hid->phys;
input_dev->id.bustype = BUS_ADB;
Expand Down
11 changes: 10 additions & 1 deletion trunk/drivers/mfd/ucb1x00-ts.c
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,16 @@ static int ucb1x00_thread(void *_ts)
struct ucb1x00_ts *ts = _ts;
struct task_struct *tsk = current;
DECLARE_WAITQUEUE(wait, tsk);
int valid = 0;
int valid;

/*
* We could run as a real-time thread. However, thus far
* this doesn't seem to be necessary.
*/
// tsk->policy = SCHED_FIFO;
// tsk->rt_priority = 1;

valid = 0;

add_wait_queue(&ts->irq_wait, &wait);
while (!kthread_should_stop()) {
Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/usb/serial/omninet.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,10 @@ static int omninet_open (struct usb_serial_port *port, struct file *filp)
{
struct usb_serial *serial = port->serial;
struct usb_serial_port *wport;
struct omninet_data *od = usb_get_serial_port_data(port);
int result = 0;

dbg("%s - port %d", __FUNCTION__, port->number);

od = kmalloc( sizeof(struct omninet_data), GFP_KERNEL );
wport = serial->port[1];
wport->tty = port->tty;

Expand Down

0 comments on commit 51d1ed4

Please sign in to comment.