From: Kylene Jo Hall <kjhall@us.ibm.com>
To: linux-kernel <linux-kernel@vger.kernel.org>
Cc: akpm@osdl.org,
TPM Device Driver List <tpmdd-devel@lists.sourceforge.net>
Subject: [PATCH] tpm: check mem start and len
Date: Wed, 12 Apr 2006 16:48:06 -0500 [thread overview]
Message-ID: <1144878487.12054.93.camel@localhost.localdomain> (raw)
The memory start and length values obtained from the ACPI entry need to
be checked and filled in with the default values from the specification
if they don't exist. This patch fills in the default values and uses
them appropriately.
Signed-off-by: Kylie Hall <kjhall@us.ibm.com>
---
drivers/char/tpm/tpm_tis.c | 7 +++++++
1 files changed, 7 insertions(+)
--- linux-2.6.17-rc1-mm2/drivers/char/tpm/tpm_tis.c 2006-04-12 16:39:40.191345000 -0500
+++ linux-2.6.17-rc1/drivers/char/tpm/tpm_tis.c 2006-04-12 14:49:13.033173500 -0500
@@ -52,6 +52,8 @@ enum tis_int_flags {
};
enum tis_defaults {
+ TIS_MEM_BASE = 0xFED4000,
+ TIS_MEM_LEN = 0x5000,
TIS_SHORT_TIMEOUT = 750, /* ms */
TIS_LONG_TIMEOUT = 2000, /* 2 sec */
};
@@ -437,6 +439,11 @@ static int __devinit tpm_tis_pnp_init(st
start = pnp_mem_start(pnp_dev, 0);
len = pnp_mem_len(pnp_dev, 0);
+ if (!start)
+ start = TIS_MEM_BASE;
+ if (!len)
+ len = TIS_MEM_LEN;
+
if (!(chip = tpm_register_hardware(&pnp_dev->dev, &tpm_tis)))
return -ENODEV;
reply other threads:[~2006-04-12 21:47 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1144878487.12054.93.camel@localhost.localdomain \
--to=kjhall@us.ibm.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tpmdd-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®