aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBorislav Petkov <borislav.petkov@amd.com>2011-01-13 13:03:28 -0500
committerBorislav Petkov <borislav.petkov@amd.com>2011-03-17 09:46:10 -0400
commitb6a280bb96e0981a527d26cfb0fad203cb9bd808 (patch)
treec788efac44d4208211f7f4086afad25544f04d0b /drivers
parent521cb40b0c44418a4fd36dc633f575813d59a43d (diff)
EDAC: Shut up sysfs registration debug code
Raise the debug level of these routines so that their output get issued out only when the highest debug level is selected. Otherwise, don't pollute driver debug output. Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/edac/edac_mc_sysfs.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/drivers/edac/edac_mc_sysfs.c b/drivers/edac/edac_mc_sysfs.c
index 39d97cfdf58c..73196f7b7229 100644
--- a/drivers/edac/edac_mc_sysfs.c
+++ b/drivers/edac/edac_mc_sysfs.c
@@ -785,10 +785,10 @@ static int edac_create_mci_instance_attributes(struct mem_ctl_info *mci,
785{ 785{
786 int err; 786 int err;
787 787
788 debugf1("%s()\n", __func__); 788 debugf4("%s()\n", __func__);
789 789
790 while (sysfs_attrib) { 790 while (sysfs_attrib) {
791 debugf1("%s() sysfs_attrib = %p\n",__func__, sysfs_attrib); 791 debugf4("%s() sysfs_attrib = %p\n",__func__, sysfs_attrib);
792 if (sysfs_attrib->grp) { 792 if (sysfs_attrib->grp) {
793 struct mcidev_sysfs_group_kobj *grp_kobj; 793 struct mcidev_sysfs_group_kobj *grp_kobj;
794 794
@@ -818,7 +818,7 @@ static int edac_create_mci_instance_attributes(struct mem_ctl_info *mci,
818 if (err < 0) 818 if (err < 0)
819 return err; 819 return err;
820 } else if (sysfs_attrib->attr.name) { 820 } else if (sysfs_attrib->attr.name) {
821 debugf0("%s() file %s\n", __func__, 821 debugf4("%s() file %s\n", __func__,
822 sysfs_attrib->attr.name); 822 sysfs_attrib->attr.name);
823 823
824 err = sysfs_create_file(kobj, &sysfs_attrib->attr); 824 err = sysfs_create_file(kobj, &sysfs_attrib->attr);
@@ -853,26 +853,26 @@ static void edac_remove_mci_instance_attributes(struct mem_ctl_info *mci,
853 * Remove first all the atributes 853 * Remove first all the atributes
854 */ 854 */
855 while (sysfs_attrib) { 855 while (sysfs_attrib) {
856 debugf1("%s() sysfs_attrib = %p\n",__func__, sysfs_attrib); 856 debugf4("%s() sysfs_attrib = %p\n",__func__, sysfs_attrib);
857 if (sysfs_attrib->grp) { 857 if (sysfs_attrib->grp) {
858 debugf1("%s() seeking for group %s\n", 858 debugf4("%s() seeking for group %s\n",
859 __func__, sysfs_attrib->grp->name); 859 __func__, sysfs_attrib->grp->name);
860 list_for_each_entry(grp_kobj, 860 list_for_each_entry(grp_kobj,
861 &mci->grp_kobj_list, list) { 861 &mci->grp_kobj_list, list) {
862 debugf1("%s() grp_kobj->grp = %p\n",__func__, grp_kobj->grp); 862 debugf4("%s() grp_kobj->grp = %p\n",__func__, grp_kobj->grp);
863 if (grp_kobj->grp == sysfs_attrib->grp) { 863 if (grp_kobj->grp == sysfs_attrib->grp) {
864 edac_remove_mci_instance_attributes(mci, 864 edac_remove_mci_instance_attributes(mci,
865 grp_kobj->grp->mcidev_attr, 865 grp_kobj->grp->mcidev_attr,
866 &grp_kobj->kobj, count + 1); 866 &grp_kobj->kobj, count + 1);
867 debugf0("%s() group %s\n", __func__, 867 debugf4("%s() group %s\n", __func__,
868 sysfs_attrib->grp->name); 868 sysfs_attrib->grp->name);
869 kobject_put(&grp_kobj->kobj); 869 kobject_put(&grp_kobj->kobj);
870 } 870 }
871 } 871 }
872 debugf1("%s() end of seeking for group %s\n", 872 debugf4("%s() end of seeking for group %s\n",
873 __func__, sysfs_attrib->grp->name); 873 __func__, sysfs_attrib->grp->name);
874 } else if (sysfs_attrib->attr.name) { 874 } else if (sysfs_attrib->attr.name) {
875 debugf0("%s() file %s\n", __func__, 875 debugf4("%s() file %s\n", __func__,
876 sysfs_attrib->attr.name); 876 sysfs_attrib->attr.name);
877 sysfs_remove_file(kobj, &sysfs_attrib->attr); 877 sysfs_remove_file(kobj, &sysfs_attrib->attr);
878 } else 878 } else
@@ -979,7 +979,7 @@ void edac_remove_sysfs_mci_device(struct mem_ctl_info *mci)
979 debugf0("%s()\n", __func__); 979 debugf0("%s()\n", __func__);
980 980
981 /* remove all csrow kobjects */ 981 /* remove all csrow kobjects */
982 debugf0("%s() unregister this mci kobj\n", __func__); 982 debugf4("%s() unregister this mci kobj\n", __func__);
983 for (i = 0; i < mci->nr_csrows; i++) { 983 for (i = 0; i < mci->nr_csrows; i++) {
984 if (mci->csrows[i].nr_pages > 0) { 984 if (mci->csrows[i].nr_pages > 0) {
985 debugf0("%s() unreg csrow-%d\n", __func__, i); 985 debugf0("%s() unreg csrow-%d\n", __func__, i);
@@ -989,18 +989,18 @@ void edac_remove_sysfs_mci_device(struct mem_ctl_info *mci)
989 989
990 /* remove this mci instance's attribtes */ 990 /* remove this mci instance's attribtes */
991 if (mci->mc_driver_sysfs_attributes) { 991 if (mci->mc_driver_sysfs_attributes) {
992 debugf0("%s() unregister mci private attributes\n", __func__); 992 debugf4("%s() unregister mci private attributes\n", __func__);
993 edac_remove_mci_instance_attributes(mci, 993 edac_remove_mci_instance_attributes(mci,
994 mci->mc_driver_sysfs_attributes, 994 mci->mc_driver_sysfs_attributes,
995 &mci->edac_mci_kobj, 0); 995 &mci->edac_mci_kobj, 0);
996 } 996 }
997 997
998 /* remove the symlink */ 998 /* remove the symlink */
999 debugf0("%s() remove_link\n", __func__); 999 debugf4("%s() remove_link\n", __func__);
1000 sysfs_remove_link(&mci->edac_mci_kobj, EDAC_DEVICE_SYMLINK); 1000 sysfs_remove_link(&mci->edac_mci_kobj, EDAC_DEVICE_SYMLINK);
1001 1001
1002 /* unregister this instance's kobject */ 1002 /* unregister this instance's kobject */
1003 debugf0("%s() remove_mci_instance\n", __func__); 1003 debugf4("%s() remove_mci_instance\n", __func__);
1004 kobject_put(&mci->edac_mci_kobj); 1004 kobject_put(&mci->edac_mci_kobj);
1005} 1005}
1006 1006