aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/sctop.py
diff options
context:
space:
mode:
authorHans Rosenfeld <hans.rosenfeld@amd.com>2010-10-29 11:14:31 -0400
committerBorislav Petkov <borislav.petkov@amd.com>2010-11-18 09:53:05 -0500
commit9653a5c76c8677b05b45b3b999d3b39988d2a064 (patch)
tree9224748c69296fc6ac50beae72f20e6e2ae16aca /tools/perf/scripts/python/sctop.py
parenteec1d4fa00c6552ae2fdf71d59f1eded7c88dd89 (diff)
x86, amd-nb: Cleanup AMD northbridge caching code
Support more than just the "Misc Control" part of the northbridges. Support more flags by turning "gart_supported" into a single bit flag that is stored in a flags member. Clean up related code by using a set of functions (amd_nb_num(), amd_nb_has_feature() and node_to_amd_nb()) instead of accessing the NB data structures directly. Reorder the initialization code and put the GART flush words caching in a separate function. Signed-off-by: Hans Rosenfeld <hans.rosenfeld@amd.com> Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions
e; struct Scsi_Host *shost; struct list_head *l; int error; if (!sht->release) { printk(KERN_ERR "scsi HBA driver %s didn't set a release method.\n", sht->name); return -EINVAL; } sht->module = THIS_MODULE; INIT_LIST_HEAD(&sht->legacy_hosts); sht->detect(sht); if (list_empty(&sht->legacy_hosts)) return -ENODEV; list_for_each_entry(shost, &sht->legacy_hosts, sht_legacy_list) { error = scsi_add_host(shost, NULL); if (error) goto fail; scsi_scan_host(shost); } return 0; fail: l = &shost->sht_legacy_list; while ((l = l->prev) != &sht->legacy_hosts) scsi_remove_host(list_entry(l, struct Scsi_Host, sht_legacy_list)); return error; } static void __exit exit_this_scsi_driver(void) { struct scsi_host_template *sht = &driver_template; struct Scsi_Host *shost, *s; list_for_each_entry(shost, &sht->legacy_hosts, sht_legacy_list) scsi_remove_host(shost); list_for_each_entry_safe(shost, s, &sht->legacy_hosts, sht_legacy_list) sht->release(shost); if (list_empty(&sht->legacy_hosts)) return; printk(KERN_WARNING "%s did not call scsi_unregister\n", sht->name); dump_stack(); list_for_each_entry_safe(shost, s, &sht->legacy_hosts, sht_legacy_list) scsi_unregister(shost); } module_init(init_this_scsi_driver); module_exit(exit_this_scsi_driver);