1/******************************************************************************* 2 * 3 * Module Name: rsmem24 - Memory resource descriptors |
4 * $Revision: 20 $ |
5 * 6 ******************************************************************************/ 7 8/****************************************************************************** 9 * 10 * 1. Copyright Notice 11 * 12 * Some or all of this work - Copyright (c) 1999 - 2002, Intel Corp. --- 134 unchanged lines hidden (view full) --- 147ACPI_STATUS 148AcpiRsMemory24Resource ( 149 UINT8 *ByteStreamBuffer, 150 ACPI_SIZE *BytesConsumed, 151 UINT8 **OutputBuffer, 152 ACPI_SIZE *StructureSize) 153{ 154 UINT8 *Buffer = ByteStreamBuffer; |
155 ACPI_RESOURCE *OutputStruct = (void *) *OutputBuffer; |
156 UINT16 Temp16 = 0; 157 UINT8 Temp8 = 0; 158 ACPI_SIZE StructSize = ACPI_SIZEOF_RESOURCE (ACPI_RESOURCE_MEM24); 159 160 161 ACPI_FUNCTION_TRACE ("RsMemory24Resource"); 162 163 164 /* 165 * Point past the Descriptor to get the number of bytes consumed 166 */ 167 Buffer += 1; 168 169 ACPI_MOVE_UNALIGNED16_TO_16 (&Temp16, Buffer); 170 Buffer += 2; |
171 *BytesConsumed = (ACPI_SIZE) Temp16 + 3; |
172 OutputStruct->Id = ACPI_RSTYPE_MEM24; 173 174 /* 175 * Check Byte 3 the Read/Write bit 176 */ 177 Temp8 = *Buffer; 178 Buffer += 1; 179 OutputStruct->Data.Memory24.ReadWriteAttribute = Temp8 & 0x01; --- 23 unchanged lines hidden (view full) --- 203 * Get RangeLength (Bytes 10-11) 204 */ 205 ACPI_MOVE_UNALIGNED16_TO_16 (&Temp16, Buffer); 206 OutputStruct->Data.Memory24.RangeLength = Temp16; 207 208 /* 209 * Set the Length parameter 210 */ |
211 OutputStruct->Length = (UINT32) StructSize; |
212 213 /* 214 * Return the final size of the structure 215 */ 216 *StructureSize = StructSize; 217 return_ACPI_STATUS (AE_OK); 218} 219 --- 104 unchanged lines hidden (view full) --- 324ACPI_STATUS 325AcpiRsMemory32RangeResource ( 326 UINT8 *ByteStreamBuffer, 327 ACPI_SIZE *BytesConsumed, 328 UINT8 **OutputBuffer, 329 ACPI_SIZE *StructureSize) 330{ 331 UINT8 *Buffer = ByteStreamBuffer; |
332 ACPI_RESOURCE *OutputStruct = (void *) *OutputBuffer; |
333 UINT16 Temp16 = 0; 334 UINT8 Temp8 = 0; 335 ACPI_SIZE StructSize = ACPI_SIZEOF_RESOURCE (ACPI_RESOURCE_MEM32); 336 337 338 ACPI_FUNCTION_TRACE ("RsMemory32RangeResource"); 339 340 341 /* 342 * Point past the Descriptor to get the number of bytes consumed 343 */ 344 Buffer += 1; 345 346 ACPI_MOVE_UNALIGNED16_TO_16 (&Temp16, Buffer); 347 Buffer += 2; |
348 *BytesConsumed = (ACPI_SIZE) Temp16 + 3; |
349 350 OutputStruct->Id = ACPI_RSTYPE_MEM32; 351 352 /* 353 * Point to the place in the output buffer where the data portion will 354 * begin. 355 * 1. Set the RESOURCE_DATA * Data to point to it's own address, then 356 * 2. Set the pointer to the next address. --- 33 unchanged lines hidden (view full) --- 390 /* 391 * Get RangeLength (Bytes 16-19) 392 */ 393 ACPI_MOVE_UNALIGNED32_TO_32 (&OutputStruct->Data.Memory32.RangeLength, Buffer); 394 395 /* 396 * Set the Length parameter 397 */ |
398 OutputStruct->Length = (UINT32) StructSize; |
399 400 /* 401 * Return the final size of the structure 402 */ 403 *StructureSize = StructSize; 404 return_ACPI_STATUS (AE_OK); 405} 406 --- 22 unchanged lines hidden (view full) --- 429ACPI_STATUS 430AcpiRsFixedMemory32Resource ( 431 UINT8 *ByteStreamBuffer, 432 ACPI_SIZE *BytesConsumed, 433 UINT8 **OutputBuffer, 434 ACPI_SIZE *StructureSize) 435{ 436 UINT8 *Buffer = ByteStreamBuffer; |
437 ACPI_RESOURCE *OutputStruct = (void *) *OutputBuffer; |
438 UINT16 Temp16 = 0; 439 UINT8 Temp8 = 0; 440 ACPI_SIZE StructSize = ACPI_SIZEOF_RESOURCE (ACPI_RESOURCE_FIXED_MEM32); 441 442 443 ACPI_FUNCTION_TRACE ("RsFixedMemory32Resource"); 444 445 446 /* 447 * Point past the Descriptor to get the number of bytes consumed 448 */ 449 Buffer += 1; 450 ACPI_MOVE_UNALIGNED16_TO_16 (&Temp16, Buffer); 451 452 Buffer += 2; |
453 *BytesConsumed = (ACPI_SIZE) Temp16 + 3; |
454 455 OutputStruct->Id = ACPI_RSTYPE_FIXED_MEM32; 456 457 /* 458 * Check Byte 3 the Read/Write bit 459 */ 460 Temp8 = *Buffer; 461 Buffer += 1; --- 10 unchanged lines hidden (view full) --- 472 * Get RangeLength (Bytes 8-11) 473 */ 474 ACPI_MOVE_UNALIGNED32_TO_32 (&OutputStruct->Data.FixedMemory32.RangeLength, 475 Buffer); 476 477 /* 478 * Set the Length parameter 479 */ |
480 OutputStruct->Length = (UINT32) StructSize; |
481 482 /* 483 * Return the final size of the structure 484 */ 485 *StructureSize = StructSize; 486 return_ACPI_STATUS (AE_OK); 487} 488 --- 156 unchanged lines hidden --- |