Chameleon

Chameleon Commit Details

Date:2011-06-12 10:30:57 (12 years 10 months ago)
Author:Kabyl
Commit:1003
Parents: 1002
Message:return default strings for SMBMemoryDevice records only for Intel (supported) chipsets
Changes:
M/trunk/i386/libsaio/platform.c
M/trunk/i386/libsaio/smbios_getters.c
M/trunk/i386/libsaio/bootstruct.h

File differences

trunk/i386/libsaio/bootstruct.h
137137
138138
139139
140
141
140142
141143
142144
config_file_t smbiosConfig; // smbios.plist
config_file_t helperConfig; // boot helper partition's boot.plist
config_file_t ramdiskConfig; // RAMDisk.plist
bool memDetect;
} PrivateBootInfo_t;
extern PrivateBootInfo_t *bootInfo;
trunk/i386/libsaio/platform.c
4141
4242
4343
44
45
44
45
46
47
48
49
50
4651
47
48
52
53
4954
5055
5156
static bool done = false;
if (done) return;
bool useAutodetection = true;
getBoolForKey(kUseMemDetect, &useAutodetection, &bootInfo->bootConfig);
/* our code only works on Intel chipsets so make sure here */
if (pci_config_read16(PCIADDR(0, 0x00, 0), 0x00) != 0x8086)
bootInfo->memDetect = false;
else
bootInfo->memDetect = true;
/* manually */
getBoolForKey(kUseMemDetect, &bootInfo->memDetect, &bootInfo->bootConfig);
if (useAutodetection) {
if (dram_controller_dev!=NULL) {
if (bootInfo->memDetect) {
if (dram_controller_dev != NULL) {
scan_dram_controller(dram_controller_dev); // Rek: pci dev ram controller direct and fully informative scan ...
}
scan_spd(&Platform);
trunk/i386/libsaio/smbios_getters.c
66
77
88
9
910
1011
1112
......
245246
246247
247248
248
249
250
249
250
251
252
251253
252254
253255
......
267269
268270
269271
270
271
272
272
273
274
275
273276
274277
275278
......
289292
290293
291294
292
293
294
295
296
297
298
295299
296300
297301
*/
#include "smbios_getters.h"
#include "bootstruct.h"
#ifndef DEBUG_SMBIOS
#define DEBUG_SMBIOS 0
}
}
return false;
//value->string = NOT_AVAILABLE;
//return true;
if (!bootInfo->memDetect)
return false;
value->string = NOT_AVAILABLE;
return true;
}
bool getSMBMemoryDeviceSerialNumber(returnType *value)
}
}
return false;
//value->string = NOT_AVAILABLE;
//return true;
if (!bootInfo->memDetect)
return false;
value->string = NOT_AVAILABLE;
return true;
}
bool getSMBMemoryDevicePartNumber(returnType *value)
}
}
return false;
//value->string = NOT_AVAILABLE;
//return true;
if (!bootInfo->memDetect)
return false;
value->string = NOT_AVAILABLE;
return true;
}

Archive Download the corresponding diff file

Revision: 1003