Commit cef2cf07 authored by Jiri Slaby's avatar Jiri Slaby Committed by Linus Torvalds

Misc: add sensable phantom driver

Add sensable phantom driver
Signed-off-by: default avatarJiri Slaby <jirislaby@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 6f7f02e7
...@@ -138,7 +138,8 @@ Code Seq# Include File Comments ...@@ -138,7 +138,8 @@ Code Seq# Include File Comments
'm' 00-1F net/irda/irmod.h conflict! 'm' 00-1F net/irda/irmod.h conflict!
'n' 00-7F linux/ncp_fs.h 'n' 00-7F linux/ncp_fs.h
'n' E0-FF video/matrox.h matroxfb 'n' E0-FF video/matrox.h matroxfb
'p' 00-3F linux/mc146818rtc.h 'p' 00-0F linux/phantom.h conflict! (OpenHaptics needs this)
'p' 00-3F linux/mc146818rtc.h conflict!
'p' 40-7F linux/nvram.h 'p' 40-7F linux/nvram.h
'p' 80-9F user-space parport 'p' 80-9F user-space parport
<mailto:tim@cyberelk.net> <mailto:tim@cyberelk.net>
......
...@@ -3108,6 +3108,11 @@ L: selinux@tycho.nsa.gov (subscribers-only, general discussion) ...@@ -3108,6 +3108,11 @@ L: selinux@tycho.nsa.gov (subscribers-only, general discussion)
W: http://www.nsa.gov/selinux W: http://www.nsa.gov/selinux
S: Supported S: Supported
SENSABLE PHANTOM
P: Jiri Slaby
M: jirislaby@gmail.com
S: Maintained
SERIAL ATA (SATA) SUBSYSTEM: SERIAL ATA (SATA) SUBSYSTEM:
P: Jeff Garzik P: Jeff Garzik
M: jgarzik@pobox.com M: jgarzik@pobox.com
......
...@@ -25,6 +25,15 @@ config IBM_ASM ...@@ -25,6 +25,15 @@ config IBM_ASM
information on the specific driver level and support statement information on the specific driver level and support statement
for your IBM server. for your IBM server.
config PHANTOM
tristate "Sensable PHANToM"
depends on PCI
help
Say Y here if you want to build a driver for Sensable PHANToM device.
If you choose to build module, its name will be phantom. If unsure,
say N here.
If unsure, say N. If unsure, say N.
......
...@@ -11,6 +11,7 @@ obj-$(CONFIG_BLINK) += blink.o ...@@ -11,6 +11,7 @@ obj-$(CONFIG_BLINK) += blink.o
obj-$(CONFIG_LKDTM) += lkdtm.o obj-$(CONFIG_LKDTM) += lkdtm.o
obj-$(CONFIG_TIFM_CORE) += tifm_core.o obj-$(CONFIG_TIFM_CORE) += tifm_core.o
obj-$(CONFIG_TIFM_7XX1) += tifm_7xx1.o obj-$(CONFIG_TIFM_7XX1) += tifm_7xx1.o
obj-$(CONFIG_PHANTOM) += phantom.o
obj-$(CONFIG_SGI_IOC4) += ioc4.o obj-$(CONFIG_SGI_IOC4) += ioc4.o
obj-$(CONFIG_SONY_LAPTOP) += sony-laptop.o obj-$(CONFIG_SONY_LAPTOP) += sony-laptop.o
obj-$(CONFIG_THINKPAD_ACPI) += thinkpad_acpi.o obj-$(CONFIG_THINKPAD_ACPI) += thinkpad_acpi.o
This diff is collapsed.
...@@ -121,6 +121,7 @@ header-y += pci_regs.h ...@@ -121,6 +121,7 @@ header-y += pci_regs.h
header-y += personality.h header-y += personality.h
header-y += pfkeyv2.h header-y += pfkeyv2.h
header-y += pg.h header-y += pg.h
header-y += phantom.h
header-y += pkt_cls.h header-y += pkt_cls.h
header-y += pkt_sched.h header-y += pkt_sched.h
header-y += posix_types.h header-y += posix_types.h
......
/*
* Copyright (C) 2005-2007 Jiri Slaby <jirislaby@gmail.com>
*
* 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 Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/
#ifndef __PHANTOM_H
#define __PHANTOM_H
#include <asm/types.h>
/* PHN_(G/S)ET_REG param */
struct phm_reg {
__u32 reg;
__u32 value;
};
/* PHN_(G/S)ET_REGS param */
struct phm_regs {
__u32 count;
__u32 mask;
__u32 values[8];
};
#define PH_IOC_MAGIC 'p'
#define PHN_GET_REG _IOWR(PH_IOC_MAGIC, 0, struct phm_reg *)
#define PHN_SET_REG _IOW (PH_IOC_MAGIC, 1, struct phm_reg *)
#define PHN_GET_REGS _IOWR(PH_IOC_MAGIC, 2, struct phm_regs *)
#define PHN_SET_REGS _IOW (PH_IOC_MAGIC, 3, struct phm_regs *)
#define PH_IOC_MAXNR 3
#define PHN_CONTROL 0x6 /* control byte in iaddr space */
#define PHN_CTL_AMP 0x1 /* switch after torques change */
#define PHN_CTL_BUT 0x2 /* is button switched */
#define PHN_CTL_IRQ 0x10 /* is irq enabled */
#define PHN_ZERO_FORCE 2048 /* zero torque on motor */
#endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment