|
|
a5bd9f6 |
From b2f7a41fb3505137cd02a22913787ec45512aaad Mon Sep 17 00:00:00 2001
|
|
|
a5bd9f6 |
From: Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>
|
|
|
a5bd9f6 |
Date: Sat, 2 Mar 2013 23:59:05 +0100
|
|
|
a5bd9f6 |
Subject: [PATCH 188/364] * include/grub/cmos.h: Handle high CMOS
|
|
|
a5bd9f6 |
addresses on sparc64.
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
---
|
|
|
a5bd9f6 |
ChangeLog | 4 ++++
|
|
|
a5bd9f6 |
include/grub/cmos.h | 8 ++++----
|
|
|
a5bd9f6 |
2 files changed, 8 insertions(+), 4 deletions(-)
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
diff --git a/ChangeLog b/ChangeLog
|
|
|
a5bd9f6 |
index 93a8a93..ea87229 100644
|
|
|
a5bd9f6 |
--- a/ChangeLog
|
|
|
a5bd9f6 |
+++ b/ChangeLog
|
|
|
a5bd9f6 |
@@ -1,5 +1,9 @@
|
|
|
a5bd9f6 |
2013-03-02 Vladimir Serbinenko <phcoder@gmail.com>
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
+ * include/grub/cmos.h: Handle high CMOS addresses on sparc64.
|
|
|
a5bd9f6 |
+
|
|
|
a5bd9f6 |
+2013-03-02 Vladimir Serbinenko <phcoder@gmail.com>
|
|
|
a5bd9f6 |
+
|
|
|
a5bd9f6 |
* include/grub/mips/loongson/cmos.h: Fix high CMOS addresses.
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
2013-03-02 Vladimir Serbinenko <phcoder@gmail.com>
|
|
|
a5bd9f6 |
diff --git a/include/grub/cmos.h b/include/grub/cmos.h
|
|
|
a5bd9f6 |
index aa2b233..56ccc71 100644
|
|
|
a5bd9f6 |
--- a/include/grub/cmos.h
|
|
|
a5bd9f6 |
+++ b/include/grub/cmos.h
|
|
|
a5bd9f6 |
@@ -103,8 +103,8 @@ grub_cmos_read (grub_uint8_t index, grub_uint8_t *val)
|
|
|
a5bd9f6 |
if (err)
|
|
|
a5bd9f6 |
return err;
|
|
|
a5bd9f6 |
}
|
|
|
a5bd9f6 |
- grub_cmos_port[0] = index;
|
|
|
a5bd9f6 |
- *val = grub_cmos_port[1];
|
|
|
a5bd9f6 |
+ grub_cmos_port[((index & 0x80) >> 6) | 0] = index & 0x7f;
|
|
|
a5bd9f6 |
+ *val = grub_cmos_port[((index & 0x80) >> 6) | 1];
|
|
|
a5bd9f6 |
return GRUB_ERR_NONE;
|
|
|
a5bd9f6 |
}
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
@@ -118,8 +118,8 @@ grub_cmos_write (grub_uint8_t index, grub_uint8_t val)
|
|
|
a5bd9f6 |
if (err)
|
|
|
a5bd9f6 |
return err;
|
|
|
a5bd9f6 |
}
|
|
|
a5bd9f6 |
- grub_cmos_port[0] = index;
|
|
|
a5bd9f6 |
- grub_cmos_port[1] = val;
|
|
|
a5bd9f6 |
+ grub_cmos_port[((index & 0x80) >> 6) | 0] = index;
|
|
|
a5bd9f6 |
+ grub_cmos_port[((index & 0x80) >> 6) | 1] = val;
|
|
|
a5bd9f6 |
return GRUB_ERR_NONE;
|
|
|
a5bd9f6 |
}
|
|
|
a5bd9f6 |
|
|
|
a5bd9f6 |
--
|
|
|
a5bd9f6 |
1.8.1.4
|
|
|
a5bd9f6 |
|