What's the overhead of a system call compared to the cost of the actual flush operation? What's the expected use case (specifically number of bytes flushed) of this call? (Maybe this is completely out of our control).
This is a flush (and invalidate) operation, not a true invalidate operation I assume, so it could be performed completely in user space, no supervisor privileges required. Is a user space implementation (using a DSO) contemplated?
-- Ola
Ola Liljedahl, Networking System Architect, ARM Telephone: +46 706 866 373 Skype: ola.liljedahl
-----Original Message----- From: Maxim Uvarov [mailto:maxim.uvarov@linaro.org] Sent: 03 October 2013 14:08 To: linaro-networking@linaro.org Cc: patches@linaro.org; linaro-kernel@lists.linaro.org; Maxim Uvarov Subject: [LNG] [PATCH] LTP cacheflush01 add arm variant
Cache flush on arm provided via __ARM_NR_cacheflush(unsigned long start, unsigned long end, int flags) defined in ./arch/arm/kernel/traps.c. Flags are not used, providing 0 there.
Signed-off-by: Maxim Uvarov maxim.uvarov@linaro.com
.../kernel/syscalls/cacheflush/cacheflush01.c | 9 +++++++++ 1 file changed, 9 insertions(+)
diff --git a/testcases/kernel/syscalls/cacheflush/cacheflush01.c b/testcases/kernel/syscalls/cacheflush/cacheflush01.c index 9c02f0a..fae51b4 100644 --- a/testcases/kernel/syscalls/cacheflush/cacheflush01.c +++ b/testcases/kernel/syscalls/cacheflush/cacheflush01.c @@ -137,6 +137,14 @@ int main(int ac, char **av) }
/* Invokes cacheflush() with proper parameters */
+#if defined(__arm__)
TEST(ltp_syscall(__ARM_NR_cacheflush, addr, addr + getpagesize(),
0));
if (TEST_RETURN == 0) {
tst_resm(TPASS, "passed with no errno");
} else {
tst_resm(TFAIL, "failed with unexpected errno");
}
+#else TEST(ltp_syscall(__NR_cacheflush, addr, getpagesize(), ICACHE)); if (TEST_RETURN == 0) { tst_resm(TPASS, "passed with no errno"); @@ -157,6 +165,7 @@ int main(int ac, char **av) } else { tst_resm(TFAIL, "failed with unexpected errno"); } +#endif
cleanup(); tst_exit();
-- 1.7.9.5
-- You received this message because you are subscribed to the Google Groups "Linaro Networking" group. To unsubscribe from this group and stop receiving emails from it, send an email to linaro-networking+unsubscribe@linaro.org. To post to this group, send email to linaro-networking@linaro.org.
-- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
ARM Limited, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2557590 ARM Holdings plc, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2548782