Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 141864
b: refs/heads/master
c: c3dd25f
h: refs/heads/master
v: v3
  • Loading branch information
Lin Ming authored and Len Brown committed Mar 27, 2009
1 parent 84d44c4 commit 188a316
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f9ca058430333c9a24c5ca926aa445125f88df18
refs/heads/master: c3dd25f4c1ca84baa170c0a3a15a884f4f06297e
4 changes: 4 additions & 0 deletions trunk/drivers/acpi/acpica/aclocal.h
Original file line number Diff line number Diff line change
Expand Up @@ -781,6 +781,10 @@ struct acpi_bit_register_info {
*/
#define ACPI_PM1_STATUS_PRESERVED_BITS 0x0800 /* Bit 11 */

/* Write-only bits must be zeroed by software */

#define ACPI_PM1_CONTROL_WRITEONLY_BITS 0x2004 /* Bits 13, 2 */

/* For control registers, both ignored and reserved bits must be preserved */

#define ACPI_PM1_CONTROL_IGNORED_BITS 0x0201 /* Bits 9, 0(SCI_EN) */
Expand Down
7 changes: 7 additions & 0 deletions trunk/drivers/acpi/acpica/hwregs.c
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,13 @@ acpi_hw_register_read(u32 register_id, u32 * return_value)
xpm1a_control_block,
&acpi_gbl_FADT.
xpm1b_control_block);

/*
* Zero the write-only bits. From the ACPI specification, "Hardware
* Write-Only Bits": "Upon reads to registers with write-only bits,
* software masks out all write-only bits."
*/
value &= ~ACPI_PM1_CONTROL_WRITEONLY_BITS;
break;

case ACPI_REGISTER_PM2_CONTROL: /* 8-bit access */
Expand Down

0 comments on commit 188a316

Please sign in to comment.