From f1fa941597af1b27278b430c1f7172fc5820d0ac Mon Sep 17 00:00:00 2001
From: gaoruoshu <gaoruoshu@huawei.com>
Date: Wed, 16 Aug 2023 12:39:37 +0800
Subject: [PATCH] [atune]update Makefile and logs

---
 Makefile                  | 10 ++++------
 common/profile/profile.go |  2 +-
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/Makefile b/Makefile
index bcac447..5c76b4e 100755
--- a/Makefile
+++ b/Makefile
@@ -46,14 +46,13 @@ clean:
 	rm -rf $(PKGPATH)/*
 
 cleanall: clean
-	rm -rf $(DESTDIR)/etc/atuned/
+	rm -rf $(DESTDIR)/etc/atune*
 	rm -rf $(DESTDIR)$(PREFIX)/lib/atuned/
 	rm -rf $(DESTDIR)$(PREFIX)/share/atuned/
 	rm -rf $(DESTDIR)$(PREFIX)/$(LIBEXEC)/atuned/
 	rm -rf $(DESTDIR)/var/lib/atuned/
 	rm -rf $(DESTDIR)/var/run/atuned/
-	rm -rf $(DESTDIR)/var/atuned/
-	rm -rf $(DESTDIR)/var/atune_data/
+	rm -rf $(DESTDIR)/var/atune*
 
 db:
 	sqlite3 database/atuned.db ".read database/init.sql"
@@ -72,14 +71,13 @@ libinstall:
 	@echo "BEGIN INSTALL A-Tune..."
 	mkdir -p $(BINDIR)
 	mkdir -p $(SYSTEMDDIR)
-	rm -rf $(DESTDIR)/etc/atuned/
+	rm -rf $(DESTDIR)/etc/atune*
 	rm -rf $(DESTDIR)$(PREFIX)/lib/atuned/
 	rm -rf $(DESTDIR)$(PREFIX)/share/atuned/
 	rm -rf $(DESTDIR)$(PREFIX)/$(LIBEXEC)/atuned/
 	rm -rf $(DESTDIR)/var/lib/atuned/
 	rm -rf $(DESTDIR)/var/run/atuned/
-	rm -rf $(DESTDIR)/var/atuned/
-	rm -rf $(DESTDIR)/var/atune_data/
+	rm -rf $(DESTDIR)/var/atune*
 	mkdir -p $(DESTDIR)/etc/atuned/tuning
 	mkdir -p $(DESTDIR)/etc/atuned/rules
 	mkdir -p $(DESTDIR)/etc/atuned/training
diff --git a/common/profile/profile.go b/common/profile/profile.go
index 264fdd8..43a4e77 100644
--- a/common/profile/profile.go
+++ b/common/profile/profile.go
@@ -294,7 +294,7 @@ func (p *Profile) ItemSort() error {
 			} else {
 				itemQuery, err := sqlstore.GetPropertyItem(key.Name())
 				if err != nil {
-					log.Errorf("key %s is not exist in tuned_item", key.Name())
+					log.Infof("key %s is not exist in tuned_item", key.Name())
 					itemName = "OTHERS"
 				} else {
 					itemName = itemQuery
-- 
2.27.0

