Skip to content

Commit 4934fbf

Browse files
committed
parisc: Show MPE/iX model string at bootup
Some (mostly 64-bit machines) machines allow to run MPE/iX and report the MPE model string via firmware call. Enhance the pdc_model_sysmodel() function to report that model string. Note that some 32-bit machines like the B160L wrongly report success for the firmware call, so include a check to prevent showing wrong info. Signed-off-by: Helge Deller <[email protected]>
1 parent 9086e60 commit 4934fbf

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

arch/parisc/include/asm/pdc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ int pdc_system_map_find_mods(struct pdc_system_map_mod_info *pdc_mod_info,
3737
int pdc_system_map_find_addrs(struct pdc_system_map_addr_info *pdc_addr_info,
3838
long mod_index, long addr_index);
3939
int pdc_model_info(struct pdc_model *model);
40-
int pdc_model_sysmodel(char *name);
40+
int pdc_model_sysmodel(unsigned int os_id, char *name);
4141
int pdc_model_cpuid(unsigned long *cpu_id);
4242
int pdc_model_versions(unsigned long *versions, int id);
4343
int pdc_model_capabilities(unsigned long *capabilities);

arch/parisc/kernel/firmware.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -527,14 +527,14 @@ int pdc_model_info(struct pdc_model *model)
527527
* Using OS_ID_HPUX will return the equivalent of the 'modelname' command
528528
* on HP/UX.
529529
*/
530-
int pdc_model_sysmodel(char *name)
530+
int pdc_model_sysmodel(unsigned int os_id, char *name)
531531
{
532532
int retval;
533533
unsigned long flags;
534534

535535
spin_lock_irqsave(&pdc_lock, flags);
536536
retval = mem_pdc_call(PDC_MODEL, PDC_MODEL_SYSMODEL, __pa(pdc_result),
537-
OS_ID_HPUX, __pa(name));
537+
os_id, __pa(name));
538538
convert_to_wide(pdc_result);
539539

540540
if (retval == PDC_OK) {

arch/parisc/kernel/processor.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,10 +272,15 @@ void __init collect_boot_cpu_data(void)
272272
printk(KERN_INFO "capabilities 0x%lx\n",
273273
boot_cpu_data.pdc.capabilities);
274274

275-
if (pdc_model_sysmodel(boot_cpu_data.pdc.sys_model_name) == PDC_OK)
276-
printk(KERN_INFO "model %s\n",
275+
if (pdc_model_sysmodel(OS_ID_HPUX, boot_cpu_data.pdc.sys_model_name) == PDC_OK)
276+
pr_info("HP-UX model name: %s\n",
277277
boot_cpu_data.pdc.sys_model_name);
278278

279+
serial_no[0] = 0;
280+
if (pdc_model_sysmodel(OS_ID_MPEXL, serial_no) == PDC_OK &&
281+
serial_no[0])
282+
pr_info("MPE/iX model name: %s\n", serial_no);
283+
279284
dump_stack_set_arch_desc("%s", boot_cpu_data.pdc.sys_model_name);
280285

281286
boot_cpu_data.hversion = boot_cpu_data.pdc.model.hversion;

0 commit comments

Comments
 (0)