[maintainer-tools PATCH 2/2] dim: add dim sparse subcommand to run sparse on a commit range

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Run sparse only on files that have changed in the range. Replace dim
checker with the new one.

Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx>
---
 dim | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/dim b/dim
index 65985bc4909a..61745b556517 100755
--- a/dim
+++ b/dim
@@ -713,11 +713,14 @@ function dim_checkpatch
 	done
 }
 
-function dim_checker
+dim_alias_checker=sparse
+function dim_sparse
 {
-	rm drivers/gpu/drm/i915/*.o &> /dev/null || true
-	rm drivers/gpu/drm/i915/*.ko &> /dev/null || true
-	make C=1 drivers/gpu/drm/i915/i915.ko
+	local range=$(rangeish "$1")
+
+	make -j5
+	touch --no-create `git diff --name-only $range` `git diff --name-only`
+	make C=1
 }
 
 function prep_pull_mail_greetings
-- 
2.1.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux