Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 22963
b: refs/heads/master
c: 289f1c7
h: refs/heads/master
i:
  22961: 90878cd
  22959: 4699f99
v: v3
  • Loading branch information
Michael Ellerman authored and Paul Mackerras committed Mar 22, 2006
1 parent eab2837 commit 792a5af
Show file tree
Hide file tree
Showing 2 changed files with 21 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: 584fc6d111c34a9a2512f6c7652dff29232bf70d
refs/heads/master: 289f1c74a9b527a816f63092e79a5412cc0352a2
20 changes: 20 additions & 0 deletions trunk/arch/powerpc/platforms/iseries/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
#include <asm/iseries/hv_call_xm.h>
#include <asm/iseries/it_lp_queue.h>
#include <asm/iseries/mf.h>
#include <asm/iseries/it_exp_vpd_panel.h>
#include <asm/iseries/hv_lp_event.h>
#include <asm/iseries/lpar_map.h>
#include <asm/udbg.h>
Expand Down Expand Up @@ -888,6 +889,24 @@ void dt_cpus(struct iseries_flat_dt *dt)
dt_end_node(dt);
}

void dt_model(struct iseries_flat_dt *dt)
{
char buf[16] = "IBM,";

/* "IBM," + mfgId[2:3] + systemSerial[1:5] */
strne2a(buf + 4, xItExtVpdPanel.mfgID + 2, 2);
strne2a(buf + 6, xItExtVpdPanel.systemSerial + 1, 5);
buf[11] = '\0';
dt_prop_str(dt, "system-id", buf);

/* "IBM," + machineType[0:4] */
strne2a(buf + 4, xItExtVpdPanel.machineType, 4);
buf[8] = '\0';
dt_prop_str(dt, "model", buf);

dt_prop_str(dt, "compatible", "IBM,iSeries");
}

void build_flat_dt(struct iseries_flat_dt *dt, unsigned long phys_mem_size)
{
u64 tmp[2];
Expand All @@ -898,6 +917,7 @@ void build_flat_dt(struct iseries_flat_dt *dt, unsigned long phys_mem_size)

dt_prop_u32(dt, "#address-cells", 2);
dt_prop_u32(dt, "#size-cells", 2);
dt_model(dt);

/* /memory */
dt_start_node(dt, "memory@0");
Expand Down

0 comments on commit 792a5af

Please sign in to comment.