}
static struct omnibook_tbl ac_table[] __initdata = {
- {XE3GF | TSP10 | TSM30X, SIMPLE_BYTE(EC, XE3GF_ADP, XE3GF_ADP_MASK)},
+ {XE3GF | TSP10 | TSM30X | TSM70, SIMPLE_BYTE(EC, XE3GF_ADP, XE3GF_ADP_MASK)},
{XE3GC | AMILOD, SIMPLE_BYTE(EC, XE3GC_STA1, XE3GC_ADP_MASK)},
{OB500 | OB510 | OB6000 | OB6100 | XE4500, SIMPLE_BYTE(EC, OB500_STA2, OB500_ADP_MASK)},
{OB4150, SIMPLE_BYTE(EC, OB4150_ADP, OB4150_ADP_MASK)},
.enabled = 0,
#endif
.read = omnibook_ac_read,
- .ectypes = XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | OB4150 | XE2 | AMILOD | TSP10 | TSM30X,
+ .ectypes = XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | OB4150 | XE2 | AMILOD | TSP10 | TSM70 | TSM30X,
.tbl = ac_table,
};
/*
- * acpi.c -- ACPI methods low-level access code for TSM30X class laptops
+ * acpi.c -- ACPI methods low-level access code for TSM70 class laptops
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* XE3GF
* TSP10
* TSM30X
+ * TSM70
*/
- if (omnibook_ectype & (XE3GF | TSP10 | TSM30X)) {
+ if (omnibook_ectype & (XE3GF | TSP10 | TSM70 | TSM30X)) {
io_op->read_addr = XE3GF_BAL;
io_op->read_mask = XE3GF_BAL0_MASK;
for (i = 0; i < num; i++)
/*
* XE3GF
* TSP10
- * TSM30X
+ * TSM70
+ * TSM30X
*/
- if (omnibook_ectype & (XE3GF | TSP10 | TSM30X)) {
+ if (omnibook_ectype & (XE3GF | TSP10 | TSM70 | TSM30X)) {
retval = omnibook_battery_present(io_op, num);
if (retval < 0)
return retval;
/*
* XE3GF
* TSP10
- * TSM30X
+ * TSM70
*/
- if (omnibook_ectype & (XE3GF | TSP10 | TSM30X)) {
+ if (omnibook_ectype & (XE3GF | TSP10 | TSM70 | TSM30X)) {
retval = omnibook_battery_present(io_op, num);
if (retval < 0)
return retval;
max = 3;
/*
* TSM30X
+ * TSM70
*/
- else if (omnibook_ectype & (TSM30X))
+ else if (omnibook_ectype & (TSM70 | TSM30X))
max = 1;
if(mutex_lock_interruptible(&io_op->backend->mutex))
}
static struct omnibook_tbl battery_table[] __initdata = {
- {XE3GF | XE3GC | AMILOD | TSP10 | TSM30X, {EC,}},
+ {XE3GF | XE3GC | AMILOD | TSP10 | TSM70 | TSM30X, {EC,}},
{0,}
};
.enabled = 0,
#endif
.read = omnibook_battery_read,
- .ectypes = XE3GF | XE3GC | AMILOD | TSP10 | TSM30X, /* FIXME: OB500|OB6000|OB6100|XE4500 */
+ .ectypes = XE3GF | XE3GC | AMILOD | TSP10 | TSM70 | TSM30X, /* FIXME: OB500|OB6000|OB6100|XE4500 */
.tbl = battery_table,
};
}
static struct omnibook_tbl blank_table[] __initdata = {
- {TSM30X, {CDI, 0, TSM100_BLANK_INDEX, 0, TSM100_LCD_OFF, TSM100_LCD_ON}},
- {XE3GF | XE3GC | AMILOD | TSP10 | TSM30X,
+ {TSM70, {CDI, 0, TSM100_BLANK_INDEX, 0, TSM100_LCD_OFF, TSM100_LCD_ON}},
+ {XE3GF | XE3GC | AMILOD | TSP10 | TSM70 | TSM30X,
COMMAND(KBC, OMNIBOOK_KBC_CMD_LCD_OFF, OMNIBOOK_KBC_CMD_LCD_ON)},
{OB500 | OB6000 | XE2, {PIO, OB500_GPO1, OB500_GPO1, 0, -OB500_BKLT_MASK, OB500_BKLT_MASK}},
{OB510 | OB6100, {PIO, OB510_GPO2, OB510_GPO2, 0, -OB510_BKLT_MASK, OB510_BKLT_MASK}},
.init = omnibook_console_blank_init,
.exit = omnibook_console_blank_cleanup,
.ectypes =
- XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE2 | AMILOD | TSP10 | TSM30X,
+ XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE2 | AMILOD | TSP10 | TSM70 | TSM30X,
.tbl = blank_table,
};
}
static struct omnibook_tbl wireless_table[] __initdata = {
- {TSM30X | TSA105, {ACPI,}}, /* stubs to select backend */
+ {TSM70 | TSA105, {ACPI,}}, /* stubs to select backend */
{TSM40, {SMI,}}, /* stubs to select backend */
{0,}
};
.read = omnibook_bt_read,
.write = omnibook_bt_write,
.init = omnibook_bt_init,
- .ectypes = TSM30X | TSM40 | TSA105,
+ .ectypes = TSM70 | TSM40 | TSA105,
.tbl = wireless_table,
};
int retval = 0;
int i;
- /* ectypes other than TSM30X have no business with this backend */
- if (!(omnibook_ectype & TSM30X))
+ /* ectypes other than TSM70 have no business with this backend */
+ if (!(omnibook_ectype & TSM70))
return -ENODEV;
if (io_op->backend->already_failed) {
static void omnibook_cdimode_exit(const struct omnibook_operation *io_op)
{
- /* ectypes other than TSM30X have no business with this backend */
- BUG_ON(!(omnibook_ectype & TSM30X));
+ /* ectypes other than TSM70 have no business with this backend */
+ BUG_ON(!(omnibook_ectype & TSM70));
dprintk("Trying to dispose cdimode\n");
kref_put(&io_op->backend->kref, cdimode_free);
}
}
static struct omnibook_tbl display_table[] __initdata = {
- {TSM30X, {ACPI,}},
+ {TSM70, {ACPI,}},
{TSM40, {SMI, SMI_GET_DISPLAY_STATE, SMI_SET_DISPLAY_STATE, 0, 0, 0}},
- {XE3GF | TSP10 | TSM30X | TSM40, SIMPLE_BYTE(EC, XE3GF_STA1, XE3GF_SHDD_MASK)},
+ {XE3GF | TSP10 | TSM70 | TSM30X | TSM40, SIMPLE_BYTE(EC, XE3GF_STA1, XE3GF_SHDD_MASK)},
{XE3GC, SIMPLE_BYTE(EC, XE3GC_STA1, XE3GC_CRTI_MASK)},
{OB500 | OB510 | OB6000 | OB6100 | XE4500, SIMPLE_BYTE(EC, OB500_STA1, OB500_CRTS_MASK)},
{OB4150, SIMPLE_BYTE(EC, OB4150_STA2, OB4150_CRST_MASK)},
.read = omnibook_display_read,
.write = omnibook_display_write,
.ectypes =
- XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | OB4150 | TSP10 | TSM30X |
+ XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | OB4150 | TSP10 | TSM70 | TSM30X |
TSM40,
.tbl = display_table,
};
Toshiba Satellite 1130 (ectype 1)
Toshiba Satellite A75 (ectype 12)
Toshiba Tecra A4 (ectype 13)
+* Split TSM30X (ectype 12) : this ectype was reimplemented and if the
+ new implementation works with Toshiba M40X, M70, M100... it does not
+ (and will never, due to hardware) with Toshiba M30X, the only way
+ to fix this is to split TSM30X (ectype 12) in :
+ -TSM70 (ectype 12) => new implementation (compal.c & acpi.c backends)
+ -TSM30X (ectype 15) => old implementation (legacy backends)
+ This is done by renaming TSM30X to TSM40 and restore old TSM30X
+ The state of the Toshiba M35X is unknown and is assigned to TSM70, one
+ should send a bug report if that fail.
+ Fix bugs 1617818 and 1605278
2.20060921 Mathieu Bérard <math_b@users.sourceforge.net>
* The minimal required kernel version is now 2.6.9 (kref API)
}
static struct omnibook_tbl hotkeys_table[] __initdata = {
- {XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | AMILOD | TSP10,
+ {XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | AMILOD | TSP10 | TSM30X,
COMMAND(KBC,OMNIBOOK_KBC_CMD_ONETOUCH_ENABLE,OMNIBOOK_KBC_CMD_ONETOUCH_DISABLE)},
- {TSM30X, {CDI,}},
+ {TSM70, {CDI,}},
{TSM40, {SMI,}},
{0,}
};
.suspend = omnibook_hotkeys_suspend,
.resume = omnibook_hotkeys_resume,
.ectypes =
- XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | AMILOD | TSP10 | TSM30X |
+ XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | AMILOD | TSP10 | TSM70 | TSM30X |
TSM40,
.tbl = hotkeys_table,
};
/*
* Maintain compatibility with the old ectype numbers:
- * ex: The user set/get ectype=12 for TSM30X=2^(12-1)
+ * ex: The user set/get ectype=12 for TSM70=2^(12-1)
*/
static int __init set_ectype_param(const char *val, struct kernel_param *kp)
{
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite A70"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite A75"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite M35X"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite M70"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "SATELLITE M100"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite M100"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Satellite M40X"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"),
DMI_MATCH(DMI_PRODUCT_NAME, "Tecra S2"),
},
- .driver_data = (void*) TSM30X
+ .driver_data = (void*) TSM70
},
{
.callback = dmi_matched,
{
/*
* FIXME: What is exactly the max value for each model ?
- * I know that it's 7 for the TSM30X, TSM40 and TSA105
+ * I know that it's 7 for the TSM30X, TSM70, TSM40 and TSA105
* and previous versions of this driver (wrongly) assumed it was 10 for
* all models.
*
* TSM30X
+ * TSM70
* TSM40
* TSA105
*/
- if (omnibook_ectype & (TSM30X | TSM40 | TSA105))
+ if (omnibook_ectype & (TSM70 | TSM30X | TSM40 | TSA105))
omnibook_max_brightness = 7;
else {
omnibook_max_brightness = 10;
}
static struct omnibook_tbl lcd_table[] __initdata = {
- {TSM30X, {CDI, TSM70_LCD_READ, TSM70_LCD_WRITE, 0, 0, 0}},
+ {TSM70, {CDI, TSM70_LCD_READ, TSM70_LCD_WRITE, 0, 0, 0}},
{TSM40, {SMI, SMI_GET_LCD_BRIGHTNESS, SMI_SET_LCD_BRIGHTNESS, 0, 0, 0}},
- {XE3GF | TSP10 | TSM30X, SIMPLE_BYTE(EC, XE3GF_BRTS, XE3GF_BRTS_MASK)},
+ {XE3GF | TSP10 | TSM70 | TSM30X, SIMPLE_BYTE(EC, XE3GF_BRTS, XE3GF_BRTS_MASK)},
{XE3GC, SIMPLE_BYTE(EC, XE3GC_BTVL, XE3GC_BTVL_MASK)},
{AMILOD, SIMPLE_BYTE(EC, AMILOD_CBRG, XE3GC_BTVL_MASK)},
{TSA105, SIMPLE_BYTE(EC, A105_BNDT, A105_BNDT_MASK)},
.write = omnibook_brightness_write,
.init = omnibook_brightness_init,
.exit = omnibook_brightness_cleanup,
- .ectypes = XE3GF | XE3GC | AMILOD | TSP10 | TSM30X | TSM40 | TSA105,
+ .ectypes = XE3GF | XE3GC | AMILOD | TSP10 | TSM70 | TSM30X | TSM40 | TSA105,
.tbl = lcd_table,
};
XE2 = (1<<8), /* 9 HP OmniBook XE2 */
AMILOD = (1<<9), /* 10 Fujitsu Amilo D */
TSP10 = (1<<10), /* 11 Toshiba Satellite P10, P15, P20 and compatible */
- TSM30X = (1<<11), /* 12 Toshiba Satellite M30X, M35X, M40X, M70 and compatible */
- TSM40 = (1<<12), /* 13 Toshiba Satellite M40 M45 Tecra S1 */
- TSA105 = (1<<13) /* 14 Toshiba Satellite A105 */
+ TSM70 = (1<<11), /* 12 Toshiba Satellite M40X, M70 and compatible */
+ TSM40 = (1<<12), /* 13 Toshiba Satellite M40, M45 and Tecra S1 */
+ TSA105 = (1<<13), /* 14 Toshiba Satellite A105 and compatible (Real support is MISSING) */
+ TSM30X = (1<<14) /* 15 Toshiba Stallite M30X and compatible */
} omnibook_ectype;
-#define ALL_ECTYPES XE3GF|XE3GC|OB500|OB510|OB6000|OB6100|XE4500|OB4150|XE2|AMILOD|TSP10|TSM30X|TSM40|TSA105
+#define ALL_ECTYPES XE3GF|XE3GC|OB500|OB510|OB6000|OB6100|XE4500|OB4150|XE2|AMILOD|TSP10|TSM70|TSM40|TSA105|TSM30X
/*
* This represent a feature provided by this module
*/
#ifdef OMNIBOOK_STANDALONE
-#if (defined (CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE) || defined(CONFIG_BACKLIGHT_CLASS_DEVICE)) && (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,16)) && (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19))
+#if (defined (CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE) || defined(CONFIG_BACKLIGHT_CLASS_DEVICE)) && (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,16)) && (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,20))
#define CONFIG_OMNIBOOK_BACKLIGHT
#else
#undef CONFIG_OMNIBOOK_BACKLIGHT
}
static struct omnibook_tbl temp_table[] __initdata = {
- {XE3GF | TSP10 | TSM30X, SIMPLE_BYTE(EC, XE3GF_CTMP, 0)},
+ {XE3GF | TSP10 | TSM70 | TSM30X, SIMPLE_BYTE(EC, XE3GF_CTMP, 0)},
{XE3GC | AMILOD, SIMPLE_BYTE(EC, XE3GC_CTMP, 0)},
{OB500 | OB510 | OB6000 | OB6100 | XE4500 | XE2, SIMPLE_BYTE(EC, OB500_CTMP, 0)},
{OB4150, SIMPLE_BYTE(EC, OB4150_TMP, 0)},
.read = omnibook_temperature_read,
.ectypes =
XE3GF | XE3GC | OB500 | OB510 | OB6000 | OB6100 | XE4500 | OB4150 | XE2 | AMILOD | TSP10
- | TSM30X,
+ | TSM70 | TSM30X,
.tbl = temp_table,
};
static struct omnibook_tbl touchpad_table[] __initdata = {
{XE3GF | XE3GC | TSP10,
COMMAND(KBC, OMNIBOOK_KBC_CMD_TOUCHPAD_ENABLE, OMNIBOOK_KBC_CMD_TOUCHPAD_DISABLE)},
- {TSM30X, {CDI, 0, TSM70_FN_INDEX, 0, TSM70_TOUCHPAD_ON, TSM70_TOUCHPAD_OFF}},
+ {TSM70, {CDI, 0, TSM70_FN_INDEX, 0, TSM70_TOUCHPAD_ON, TSM70_TOUCHPAD_OFF}},
{0,}
};
.init = omnibook_touchpad_init,
.exit = omnibook_touchpad_cleanup,
.resume = omnibook_touchpad_resume,
- .ectypes = XE3GF | XE3GC | TSP10 | TSM30X,
+ .ectypes = XE3GF | XE3GC | TSP10 | TSM70,
.tbl = touchpad_table,
};
}
static struct omnibook_tbl wireless_table[] __initdata = {
- {TSM30X, {ACPI,}}, /* stubs to select backend */
+ {TSM70, {ACPI,}}, /* stubs to select backend */
{TSM40, {SMI,}}, /* stubs to select backend */
{0,}
};
.read = omnibook_wifi_read,
.write = omnibook_wifi_write,
.init = omnibook_wifi_init,
- .ectypes = TSM30X | TSM40,
+ .ectypes = TSM70 | TSM40,
.tbl = wireless_table,
};