Lines Matching refs:nb
163 struct amd_northbridge *nb; member
306 static void amd_calc_l3_indices(struct amd_northbridge *nb) in amd_calc_l3_indices() argument
308 struct amd_l3_cache *l3 = &nb->l3_cache; in amd_calc_l3_indices()
312 pci_read_config_dword(nb->misc, 0x1C4, &val); in amd_calc_l3_indices()
336 static int amd_get_l3_disable_slot(struct amd_northbridge *nb, unsigned slot) in amd_get_l3_disable_slot() argument
340 pci_read_config_dword(nb->misc, 0x1BC + slot * 4, ®); in amd_get_l3_disable_slot()
353 struct amd_northbridge *nb = this_leaf->priv; in show_cache_disable() local
355 index = amd_get_l3_disable_slot(nb, slot); in show_cache_disable()
373 static void amd_l3_disable_index(struct amd_northbridge *nb, int cpu, in amd_l3_disable_index() argument
386 if (!nb->l3_cache.subcaches[i]) in amd_l3_disable_index()
389 pci_write_config_dword(nb->misc, 0x1BC + slot * 4, reg); in amd_l3_disable_index()
399 pci_write_config_dword(nb->misc, 0x1BC + slot * 4, reg); in amd_l3_disable_index()
413 static int amd_set_l3_disable_slot(struct amd_northbridge *nb, int cpu, in amd_set_l3_disable_slot() argument
419 ret = amd_get_l3_disable_slot(nb, slot); in amd_set_l3_disable_slot()
423 if (index > nb->l3_cache.indices) in amd_set_l3_disable_slot()
427 if (index == amd_get_l3_disable_slot(nb, !slot)) in amd_set_l3_disable_slot()
430 amd_l3_disable_index(nb, cpu, slot, index); in amd_set_l3_disable_slot()
441 struct amd_northbridge *nb = this_leaf->priv; in store_cache_disable() local
451 err = amd_set_l3_disable_slot(nb, cpu, slot, val); in store_cache_disable()
564 struct amd_northbridge *nb = this_leaf->priv; in cache_get_priv_group() local
566 if (this_leaf->level < 3 || !nb) in cache_get_priv_group()
569 if (nb && nb->l3_cache.indices) in cache_get_priv_group()
584 this_leaf->nb = node_to_amd_nb(node); in amd_init_l3_cache()
585 if (this_leaf->nb && !this_leaf->nb->l3_cache.indices) in amd_init_l3_cache()
586 amd_calc_l3_indices(this_leaf->nb); in amd_init_l3_cache()
986 this_leaf->priv = base->nb; in ci_leaf_init()