All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] schedtool-dl: Fix SCHED_DEADLINE value out of range
@ 2017-06-29  9:19 zhe.he
  2017-06-29  9:31 ` ✗ patchtest: failure for " Patchwork
  0 siblings, 1 reply; 3+ messages in thread
From: zhe.he @ 2017-06-29  9:19 UTC (permalink / raw)
  To: openembedded-core

From: He Zhe <zhe.he@windriver.com>

The upstream commit 3ffb479929c31cbae09de08f94f58b8f0f061d91
tries to fix this issue but it's not complete.

This patch adds flags at the last necessary place.

Signed-off-by: He Zhe <zhe.he@windriver.com>
---
 recipes-tools/schedtool-dl/schedtool-dl.bb         |  6 ++-
 ...-add-flags-to-parameters-of-sched_setattr.patch | 56 ++++++++++++++++++++++
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 recipes-tools/schedtool-dl/schedtool-dl/0001-schedtool-dl-add-flags-to-parameters-of-sched_setattr.patch

diff --git a/recipes-tools/schedtool-dl/schedtool-dl.bb b/recipes-tools/schedtool-dl/schedtool-dl.bb
index 578e5df..20c8919 100644
--- a/recipes-tools/schedtool-dl/schedtool-dl.bb
+++ b/recipes-tools/schedtool-dl/schedtool-dl.bb
@@ -3,13 +3,17 @@ SECTION = "devel"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=dc1f51f7ca94aebffb9b3663d82873ec"
 
-SRC_URI = "git://github.com/jlelli/schedtool-dl.git;protocol=git"
+SRC_URI = "git://github.com/jlelli/schedtool-dl.git;protocol=git \
+           file://0001-schedtool-dl-add-flags-to-parameters-of-sched_setattr.patch \
+          "
 SRCREV = "3ffb479929c31cbae09de08f94f58b8f0f061d91"
 
 S = "${WORKDIR}/git"
 
 EXTRA_OEMAKE = "'CC=${CC}'"
 
+TARGET_CC_ARCH += "${LDFLAGS}"
+
 do_compile() {
 	oe_runmake
 }
diff --git a/recipes-tools/schedtool-dl/schedtool-dl/0001-schedtool-dl-add-flags-to-parameters-of-sched_setattr.patch b/recipes-tools/schedtool-dl/schedtool-dl/0001-schedtool-dl-add-flags-to-parameters-of-sched_setattr.patch
new file mode 100644
index 0000000..65d5059
--- /dev/null
+++ b/recipes-tools/schedtool-dl/schedtool-dl/0001-schedtool-dl-add-flags-to-parameters-of-sched_setattr.patch
@@ -0,0 +1,56 @@
+From c75ae0f6ac2bb9eb893cce82e93144e1b3c36389 Mon Sep 17 00:00:00 2001
+From: Qi Hou <qi.hou@windriver.com>
+Date: Wed, 16 Mar 2016 05:44:40 +0000
+Subject: [PATCH] schedtool-dl: add flags to parameters of sched_setattr
+
+git://github.com/jlelli/schedtool-dl.git;protocol=git
+commit 3ffb479929c31cbae09de08f94f58b8f0f061d91
+
+The commit numbered as 3ffb479 has adapted to the very last changes to the ABI,except for the
+syscall of sched_setattr.
+
+While executing schedtool,there was an error,like below:
+
+root@128:/opt/wr-test/testcases/kts/edf# schedtool -E -t 8000:10000 -e yes
+ERROR: could not set PID 1731 to E: SCHED_DEADLINE - value out of range / policy not implemented
+
+The cause of this case is that the syscall of sched_setattr is declared with 3 parameters,but in
+the use of it in schedtool,there was only two parameters.So to adapt this declaration,we should
+add one more parameter,flags,when calling sched_setattr.
+
+In kernel source file kernel/sched/core.c,the declaration of the syscall of sched_setattr like below:
+/**
+ * sys_sched_setattr - same as above, but with extended sched_attr
+ * @pid: the pid in question.
+ * @uattr: structure containing the extended parameters.
+ * @flags: for future extension.
+ */
+ SYSCALL_DEFINE3(sched_setattr, pid_t, pid, struct sched_attr __user *, uattr,
+                                unsigned int, flags)
+ {
+	...
+ }
+
+In schedtool-dl source file syscall_magic.h,the use of sched_setattr like below:
+        syscall(__NR_sched_setattr, pid, attr)
+
+Upstream-Status: Backport
+
+Signed-off-by: Qi Hou <qi.hou@windriver.com>
+---
+ syscall_magic.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/syscall_magic.h b/syscall_magic.h
+index 7dcb967..2735dfb 100644
+--- a/syscall_magic.h
++++ b/syscall_magic.h
+@@ -76,4 +76,4 @@ struct sched_attr {
+ 	syscall(__NR_sched_getattr, pid, attr, size, flags)
+ 
+ #define sched_setattr(pid, attr, flags) \
+-	syscall(__NR_sched_setattr, pid, attr)
++	syscall(__NR_sched_setattr, pid, attr,flags)
+-- 
+1.9.1
+
-- 
2.8.1



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* ✗ patchtest: failure for schedtool-dl: Fix SCHED_DEADLINE value out of range
  2017-06-29  9:19 [PATCH] schedtool-dl: Fix SCHED_DEADLINE value out of range zhe.he
@ 2017-06-29  9:31 ` Patchwork
  2017-06-29 12:27   ` Bruce Ashfield
  0 siblings, 1 reply; 3+ messages in thread
From: Patchwork @ 2017-06-29  9:31 UTC (permalink / raw)
  To: zhe.he; +Cc: openembedded-core

== Series Details ==

Series: schedtool-dl: Fix SCHED_DEADLINE value out of range
Revision: 1
URL   : https://patchwork.openembedded.org/series/7507/
State : failure

== Summary ==


Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:



* Issue             Series does not apply on top of target branch [test_series_merge_on_head] 
  Suggested fix    Rebase your series on top of targeted branch
  Targeted branch  master (currently at c594cacc88)



If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).

---
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ✗ patchtest: failure for schedtool-dl: Fix SCHED_DEADLINE value out of range
  2017-06-29  9:31 ` ✗ patchtest: failure for " Patchwork
@ 2017-06-29 12:27   ` Bruce Ashfield
  0 siblings, 0 replies; 3+ messages in thread
From: Bruce Ashfield @ 2017-06-29 12:27 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

[-- Attachment #1: Type: text/plain, Size: 1947 bytes --]

Zhe emailed me, and this is actually for meta-realtime. The README
indicates that
changes should be sent to oe-core .. but obviously that isn't accurate
anymore.

I'm updating the README, and this can be resent to the yocto mailing list
with
[meta-realtime] in the subject.

Cheers,

Bruce

On Thu, Jun 29, 2017 at 5:31 AM, Patchwork <
patchwork@patchwork.openembedded.org> wrote:

> == Series Details ==
>
> Series: schedtool-dl: Fix SCHED_DEADLINE value out of range
> Revision: 1
> URL   : https://patchwork.openembedded.org/series/7507/
> State : failure
>
> == Summary ==
>
>
> Thank you for submitting this patch series to OpenEmbedded Core. This is
> an automated response. Several tests have been executed on the proposed
> series by patchtest resulting in the following failures:
>
>
>
> * Issue             Series does not apply on top of target branch
> [test_series_merge_on_head]
>   Suggested fix    Rebase your series on top of targeted branch
>   Targeted branch  master (currently at c594cacc88)
>
>
>
> If you believe any of these test results are incorrect, please reply to the
> mailing list (openembedded-core@lists.openembedded.org) raising your
> concerns.
> Otherwise we would appreciate you correcting the issues and submitting a
> new
> version of the patchset if applicable. Please ensure you add/increment the
> version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
> [PATCH v3] -> ...).
>
> ---
> Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
> Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>



-- 
"Thou shalt not follow the NULL pointer, for chaos and madness await thee
at its end"

[-- Attachment #2: Type: text/html, Size: 3176 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-29 12:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-29  9:19 [PATCH] schedtool-dl: Fix SCHED_DEADLINE value out of range zhe.he
2017-06-29  9:31 ` ✗ patchtest: failure for " Patchwork
2017-06-29 12:27   ` Bruce Ashfield

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.