diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-12-05 12:44:57 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-12-05 12:44:57 -0500 |
commit | 83fdbfbfe6e7e8906e3a3f8f6bc074d887e92109 (patch) | |
tree | 977e10a076d76fdb2622f089211f3d0954ba6873 /drivers/char | |
parent | d9b2c4d0b03c721808c0d259e43a27f1e80205bc (diff) | |
parent | c84d6efd363a3948eb32ec40d46bab6338580454 (diff) |
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6
* 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6: (30 commits)
TOMOYO: Add recursive directory matching operator support.
remove CONFIG_SECURITY_FILE_CAPABILITIES compile option
SELinux: print denials for buggy kernel with unknown perms
Silence the existing API for capability version compatibility check.
LSM: Move security_path_chmod()/security_path_chown() to after mutex_lock().
SELinux: header generation may hit infinite loop
selinux: Fix warnings
security: report the module name to security_module_request
Config option to set a default LSM
sysctl: require CAP_SYS_RAWIO to set mmap_min_addr
tpm: autoload tpm_tis based on system PnP IDs
tpm_tis: TPM_STS_DATA_EXPECT workaround
define convenient securebits masks for prctl users (v2)
tpm: fix header for modular build
tomoyo: improve hash bucket dispersion
tpm add default function definitions
LSM: imbed ima calls in the security hooks
SELinux: add .gitignore files for dynamic classes
security: remove root_plug
SELinux: fix locking issue introduced with c6d3aaa4e35c71a3
...
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/tpm/tpm.c | 2 | ||||
-rw-r--r-- | drivers/char/tpm/tpm_tis.c | 11 |
2 files changed, 11 insertions, 2 deletions
diff --git a/drivers/char/tpm/tpm.c b/drivers/char/tpm/tpm.c index 47c2d2763456..f06bb37defb1 100644 --- a/drivers/char/tpm/tpm.c +++ b/drivers/char/tpm/tpm.c | |||
@@ -31,7 +31,7 @@ | |||
31 | 31 | ||
32 | enum tpm_const { | 32 | enum tpm_const { |
33 | TPM_MINOR = 224, /* officially assigned */ | 33 | TPM_MINOR = 224, /* officially assigned */ |
34 | TPM_BUFSIZE = 2048, | 34 | TPM_BUFSIZE = 4096, |
35 | TPM_NUM_DEVICES = 256, | 35 | TPM_NUM_DEVICES = 256, |
36 | }; | 36 | }; |
37 | 37 | ||
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c index 0b73e4ec1add..2405f17b29dd 100644 --- a/drivers/char/tpm/tpm_tis.c +++ b/drivers/char/tpm/tpm_tis.c | |||
@@ -257,6 +257,10 @@ out: | |||
257 | return size; | 257 | return size; |
258 | } | 258 | } |
259 | 259 | ||
260 | static int itpm; | ||
261 | module_param(itpm, bool, 0444); | ||
262 | MODULE_PARM_DESC(itpm, "Force iTPM workarounds (found on some Lenovo laptops)"); | ||
263 | |||
260 | /* | 264 | /* |
261 | * If interrupts are used (signaled by an irq set in the vendor structure) | 265 | * If interrupts are used (signaled by an irq set in the vendor structure) |
262 | * tpm.c can skip polling for the data to be available as the interrupt is | 266 | * tpm.c can skip polling for the data to be available as the interrupt is |
@@ -293,7 +297,7 @@ static int tpm_tis_send(struct tpm_chip *chip, u8 *buf, size_t len) | |||
293 | wait_for_stat(chip, TPM_STS_VALID, chip->vendor.timeout_c, | 297 | wait_for_stat(chip, TPM_STS_VALID, chip->vendor.timeout_c, |
294 | &chip->vendor.int_queue); | 298 | &chip->vendor.int_queue); |
295 | status = tpm_tis_status(chip); | 299 | status = tpm_tis_status(chip); |
296 | if ((status & TPM_STS_DATA_EXPECT) == 0) { | 300 | if (!itpm && (status & TPM_STS_DATA_EXPECT) == 0) { |
297 | rc = -EIO; | 301 | rc = -EIO; |
298 | goto out_err; | 302 | goto out_err; |
299 | } | 303 | } |
@@ -467,6 +471,10 @@ static int tpm_tis_init(struct device *dev, resource_size_t start, | |||
467 | "1.2 TPM (device-id 0x%X, rev-id %d)\n", | 471 | "1.2 TPM (device-id 0x%X, rev-id %d)\n", |
468 | vendor >> 16, ioread8(chip->vendor.iobase + TPM_RID(0))); | 472 | vendor >> 16, ioread8(chip->vendor.iobase + TPM_RID(0))); |
469 | 473 | ||
474 | if (itpm) | ||
475 | dev_info(dev, "Intel iTPM workaround enabled\n"); | ||
476 | |||
477 | |||
470 | /* Figure out the capabilities */ | 478 | /* Figure out the capabilities */ |
471 | intfcaps = | 479 | intfcaps = |
472 | ioread32(chip->vendor.iobase + | 480 | ioread32(chip->vendor.iobase + |
@@ -629,6 +637,7 @@ static struct pnp_device_id tpm_pnp_tbl[] __devinitdata = { | |||
629 | {"", 0}, /* User Specified */ | 637 | {"", 0}, /* User Specified */ |
630 | {"", 0} /* Terminator */ | 638 | {"", 0} /* Terminator */ |
631 | }; | 639 | }; |
640 | MODULE_DEVICE_TABLE(pnp, tpm_pnp_tbl); | ||
632 | 641 | ||
633 | static __devexit void tpm_tis_pnp_remove(struct pnp_dev *dev) | 642 | static __devexit void tpm_tis_pnp_remove(struct pnp_dev *dev) |
634 | { | 643 | { |