Lines Matching refs:csp

127 sbd_fill_cpu_stat(sbd_cpu_unit_t *cp, dev_info_t *dip, sbd_cpu_stat_t *csp)  in sbd_fill_cpu_stat()  argument
131 bzero((caddr_t)csp, sizeof (*csp)); in sbd_fill_cpu_stat()
132 csp->cs_type = cp->sbc_cm.sbdev_type; in sbd_fill_cpu_stat()
133 csp->cs_unit = cp->sbc_cm.sbdev_unum; in sbd_fill_cpu_stat()
134 namelen = sizeof (csp->cs_name); in sbd_fill_cpu_stat()
136 OBP_DEVICETYPE, (caddr_t)csp->cs_name, &namelen); in sbd_fill_cpu_stat()
137 csp->cs_busy = cp->sbc_cm.sbdev_busy; in sbd_fill_cpu_stat()
138 csp->cs_time = cp->sbc_cm.sbdev_time; in sbd_fill_cpu_stat()
139 csp->cs_ostate = cp->sbc_cm.sbdev_ostate; in sbd_fill_cpu_stat()
140 csp->cs_cpuid = cp->sbc_cpu_id; in sbd_fill_cpu_stat()
141 csp->cs_suspend = 0; in sbd_fill_cpu_stat()
147 if (csp->cs_cond != SBD_COND_UNUSABLE) in sbd_fill_cpu_stat()
148 csp->cs_cond = sbd_get_comp_cond(dip); in sbd_fill_cpu_stat()
158 csp->cs_speed = cp->sbc_speed; in sbd_fill_cpu_stat()
159 csp->cs_ecache = cp->sbc_ecache; in sbd_fill_cpu_stat()
163 sbd_fill_cmp_stat(sbd_cpu_stat_t *csp, int ncores, int impl, in sbd_fill_cmp_stat() argument
168 ASSERT(csp && psp && (ncores >= 1)); in sbd_fill_cmp_stat()
177 psp->ps_unit = SBD_CMP_NUM(csp->cs_unit); in sbd_fill_cmp_stat()
178 (void) strncpy(psp->ps_name, csp->cs_name, sizeof (psp->ps_name)); in sbd_fill_cmp_stat()
179 psp->ps_cond = csp->cs_cond; in sbd_fill_cmp_stat()
180 psp->ps_busy = csp->cs_busy; in sbd_fill_cmp_stat()
181 psp->ps_time = csp->cs_time; in sbd_fill_cmp_stat()
182 psp->ps_ostate = csp->cs_ostate; in sbd_fill_cmp_stat()
183 psp->ps_suspend = csp->cs_suspend; in sbd_fill_cmp_stat()
186 *psp->ps_cpuid = csp->cs_cpuid; in sbd_fill_cmp_stat()
188 psp->ps_speed = csp->cs_speed; in sbd_fill_cmp_stat()
189 psp->ps_ecache = csp->cs_ecache; in sbd_fill_cmp_stat()
202 ASSERT(psp->ps_unit == SBD_CMP_NUM(csp[core].cs_unit)); in sbd_fill_cmp_stat()
203 ASSERT(psp->ps_speed == csp[core].cs_speed); in sbd_fill_cmp_stat()
205 psp->ps_cpuid[core] = csp[core].cs_cpuid; in sbd_fill_cmp_stat()
214 psp->ps_ecache += csp[core].cs_ecache; in sbd_fill_cmp_stat()
218 if (csp[core].cs_time > psp->ps_time) { in sbd_fill_cmp_stat()
219 psp->ps_time = csp[core].cs_time; in sbd_fill_cmp_stat()
222 psp->ps_busy |= csp[core].cs_busy; in sbd_fill_cmp_stat()
228 if (csp[core].cs_ostate == SBD_STAT_CONFIGURED) { in sbd_fill_cmp_stat()
229 psp->ps_ostate = csp[core].cs_ostate; in sbd_fill_cmp_stat()