From: Frederic TEMPORELLI <frederic.temporelli@ext.bull.net>
To: Hannes Reinecke <hare@suse.de>
Cc: xb <xavier.bru@bull.net>, linux-scsi@vger.kernel.org
Subject: aic79xx - wrong max memory at driver init
Date: Thu, 30 Nov 2006 12:07:47 +0100 [thread overview]
Message-ID: <456EBB83.9010300@ext.bull.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 506 bytes --]
Hello Hannes,
Aic79xx driver for Adaptec 39320 supports 64-bit addressing, but the
initialization code of the driver is wrong: it tests the available
memory size instead of testing the maximum available memory address.
This is necessary to support servers that provides 1 Terabyte of
physical memory space addressing.
Attached is the suggested patch (made against 2.6.17, but 2.6.19 is
still using the available memory size instead of using the max memory
address) to solve this issue.
regards
--
Fred
[-- Attachment #2: aic-TBytes.patch --]
[-- Type: text/plain, Size: 897 bytes --]
Signed-off-by: xavier.bru@bull.net
Signed-off-by: frederic.temporelli@bull.net
--- linux/drivers/scsi/aic7xxx/aic79xx_osm.c 2006-08-23 23:16:33.000000000 +0200
+++ linux-new/drivers/scsi/aic7xxx/aic79xx_osm.c 2006-09-14 16:44:24.000000000 +0200
@@ -62,6 +62,7 @@
#include <linux/mm.h> /* For fetching system memory size */
+extern unsigned long blk_max_pfn;
static struct scsi_transport_template *ahd_linux_transport_template = NULL;
#include <linux/init.h> /* __setup */
@@ -1175,10 +1176,9 @@ ahd_linux_register_host(struct ahd_softc
uint64_t
ahd_linux_get_memsize(void)
{
- struct sysinfo si;
-
- si_meminfo(&si);
- return ((uint64_t)si.totalram << PAGE_SHIFT);
+ /* Need to take in account the max physical address in case
+ * of discontiguous memory. */
+ return ((uint64_t)blk_max_pfn << PAGE_SHIFT);
}
/*
next reply other threads:[~2006-11-30 11:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-30 11:07 Frederic TEMPORELLI [this message]
2006-12-14 10:37 ` aic79xx - wrong max memory at driver init Hannes Reinecke
2006-12-15 17:47 ` James Bottomley
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=456EBB83.9010300@ext.bull.net \
--to=frederic.temporelli@ext.bull.net \
--cc=hare@suse.de \
--cc=linux-scsi@vger.kernel.org \
--cc=xavier.bru@bull.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.