diff mbox

[PATCHv2,1/2] trace-cmd/kernelshark: update to 2.3.2 release (latest stable branch)

Message ID 1396965637-4802-2-git-send-email-fathi.boudra@linaro.org
State New
Headers show

Commit Message

Fathi Boudra April 8, 2014, 2 p.m. UTC
* drop all the patches - not needed anymore
  - addldflags.patch - fixed upstream in some other way
  - blktrace-api-compatibility.patch - backport
  - make-docs-optional.patch- useless since upstream has now an
    explicit build targets for the docs (doc/install_doc)
  - trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch - backport
  - trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch - backport
  - trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch - backport
 * update SRCREV and PV to 2.3.2 tag
 * drop PR
 * update SRC_URI to use trace-cmd-stable-v2.3 branch
 * drop EXTRA_OEMAKE - not needed
 * update do_install and pass NO_PYTHON/prefix/plugin_dir
 * update trace-input.c md5 sum - FSF address has been updated

Signed-off-by: Fathi Boudra <fathi.boudra@linaro.org>
---
 .../{kernelshark_1.2.bb => kernelshark_2.3.2.bb}   | 23 ++----
 .../trace-cmd/trace-cmd/addldflags.patch           | 51 ------------
 .../trace-cmd/blktrace-api-compatibility.patch     | 29 -------
 .../trace-cmd/trace-cmd/make-docs-optional.patch   | 36 --------
 ...dd-checks-for-invalid-pointers-to-fix-seg.patch | 61 --------------
 ...o-not-call-stop_threads-if-doing-latency-.patch | 38 ---------
 ...etting-plugin-to-nop-clears-data-before-i.patch | 96 ----------------------
 .../{trace-cmd_1.2.bb => trace-cmd_2.3.2.bb}       | 24 ++----
 8 files changed, 15 insertions(+), 343 deletions(-)
 rename meta/recipes-kernel/trace-cmd/{kernelshark_1.2.bb => kernelshark_2.3.2.bb} (48%)
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch
 delete mode 100644 meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch
 rename meta/recipes-kernel/trace-cmd/{trace-cmd_1.2.bb => trace-cmd_2.3.2.bb} (41%)

Comments

Khem Raj April 8, 2014, 5:05 p.m. UTC | #1
On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra <fathi.boudra@linaro.org> wrote:
>  do_install() {
> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
> +       ${MAKE} NO_PYTHON=1 prefix=${prefix} plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
>  }

can you explain/document this change
Fathi Boudra April 8, 2014, 5:16 p.m. UTC | #2
On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
> On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra <fathi.boudra@linaro.org> wrote:
>>  do_install() {
>> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
>> +       ${MAKE} NO_PYTHON=1 prefix=${prefix} plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
>>  }
>
> can you explain/document this change

sure. trace-cmd doesn't have a build system generated Makefile. It's
hand written.
To do the install properly, one has to pass prefix/plugin_dir.
In addition, the previous command in the recipe doesn't do the right
thing anymore (you'll end with duplicated prefix /usr/usr/).

I've included NO_PYTHON since the build system is still broken for
cross-compilation in some way.
I found it acceptable because the old version available in oe doesn't
have this support anyway.

In short, I took some shortcut. The right thing to do is to revisit
upstream build system and fix it. Time that I can't afford right now.
Christopher Larson April 9, 2014, 3:02 p.m. UTC | #3
On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>wrote:

> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra <fathi.boudra@linaro.org>
> wrote:
> >>  do_install() {
> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
> >>  }
> >
> > can you explain/document this change
>
> sure. trace-cmd doesn't have a build system generated Makefile. It's
> hand written.
> To do the install properly, one has to pass prefix/plugin_dir.
> In addition, the previous command in the recipe doesn't do the right
> thing anymore (you'll end with duplicated prefix /usr/usr/).


You don't need to avoid the use of oe_runmake to pass variables in, that's
what EXTRA_OEMAKE is for :) See
https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a version
of this fix that uses it instead.
Fathi Boudra April 9, 2014, 4:18 p.m. UTC | #4
On 9 April 2014 18:02, Chris Larson <clarson@kergoth.com> wrote:
>
> On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>
> wrote:
>>
>> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
>> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra <fathi.boudra@linaro.org>
>> > wrote:
>> >>  do_install() {
>> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
>> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
>> >> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
>> >>  }
>> >
>> > can you explain/document this change
>>
>> sure. trace-cmd doesn't have a build system generated Makefile. It's
>> hand written.
>> To do the install properly, one has to pass prefix/plugin_dir.
>> In addition, the previous command in the recipe doesn't do the right
>> thing anymore (you'll end with duplicated prefix /usr/usr/).
>
>
> You don't need to avoid the use of oe_runmake to pass variables in, that's
> what EXTRA_OEMAKE is for :) See
> https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a version
> of this fix that uses it instead.

You don't need oe_runmake or EXTRA_OEMAKE to properly build and
install the files in the right path either :)
You can even drop inherit pkgconfig pythonnative since they aren't
used. My version is also slightly shorter to achieve the same goal.

All in all, I don't mind which version is taken as long as we update
the one in oe-core.

Cheers,
Fathi
Christopher Larson April 9, 2014, 7:15 p.m. UTC | #5
On Wed, Apr 9, 2014 at 9:18 AM, Fathi Boudra <fathi.boudra@linaro.org>wrote:

> On 9 April 2014 18:02, Chris Larson <clarson@kergoth.com> wrote:
> >
> > On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>
> > wrote:
> >>
> >> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
> >> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra <fathi.boudra@linaro.org
> >
> >> > wrote:
> >> >>  do_install() {
> >> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
> >> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
> >> >> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
> >> >>  }
> >> >
> >> > can you explain/document this change
> >>
> >> sure. trace-cmd doesn't have a build system generated Makefile. It's
> >> hand written.
> >> To do the install properly, one has to pass prefix/plugin_dir.
> >> In addition, the previous command in the recipe doesn't do the right
> >> thing anymore (you'll end with duplicated prefix /usr/usr/).
> >
> >
> > You don't need to avoid the use of oe_runmake to pass variables in,
> that's
> > what EXTRA_OEMAKE is for :) See
> > https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a
> version
> > of this fix that uses it instead.
>
> You don't need oe_runmake or EXTRA_OEMAKE to properly build and
> install the files in the right path either :)
> You can even drop inherit pkgconfig pythonnative since they aren't
> used. My version is also slightly shorter to achieve the same goal.
>

oe_runmake is the convention used by nearly every recipe in oe-core.
Breaking that convention for no good reason accomplishes nothing.
Fathi Boudra April 9, 2014, 7:25 p.m. UTC | #6
On 9 April 2014 22:15, Chris Larson <clarson@kergoth.com> wrote:
>
> On Wed, Apr 9, 2014 at 9:18 AM, Fathi Boudra <fathi.boudra@linaro.org>
> wrote:
>>
>> On 9 April 2014 18:02, Chris Larson <clarson@kergoth.com> wrote:
>> >
>> > On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>
>> > wrote:
>> >>
>> >> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
>> >> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra
>> >> > <fathi.boudra@linaro.org>
>> >> > wrote:
>> >> >>  do_install() {
>> >> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
>> >> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
>> >> >> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
>> >> >>  }
>> >> >
>> >> > can you explain/document this change
>> >>
>> >> sure. trace-cmd doesn't have a build system generated Makefile. It's
>> >> hand written.
>> >> To do the install properly, one has to pass prefix/plugin_dir.
>> >> In addition, the previous command in the recipe doesn't do the right
>> >> thing anymore (you'll end with duplicated prefix /usr/usr/).
>> >
>> >
>> > You don't need to avoid the use of oe_runmake to pass variables in,
>> > that's
>> > what EXTRA_OEMAKE is for :) See
>> > https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a
>> > version
>> > of this fix that uses it instead.
>>
>> You don't need oe_runmake or EXTRA_OEMAKE to properly build and
>> install the files in the right path either :)
>> You can even drop inherit pkgconfig pythonnative since they aren't
>> used. My version is also slightly shorter to achieve the same goal.
>
>
> oe_runmake is the convention used by nearly every recipe in oe-core.
> Breaking that convention for no good reason accomplishes nothing.

you can argue as you prefer. reality is that  using oe_runmake on this
particular software accomplishes nothing.

my 2cts.
Dorairaj, Sanjay April 9, 2014, 7:35 p.m. UTC | #7
Hi,

Does anyone know if OE supports qtwebsockets?

Thanks,

Sanjay Dorairaj
Comcast Silicon Valley Innovation Center
1050 Enterprise Way, Suite 100
Sunnyvale, CA 94089
Desk: (408)900-8737 Cell:(215)900-2349
Skype: dorairajsanjay

>
Paul Eggleton April 15, 2014, 5:04 p.m. UTC | #8
On Wednesday 09 April 2014 22:25:31 Fathi Boudra wrote:
> On 9 April 2014 22:15, Chris Larson <clarson@kergoth.com> wrote:
> > On Wed, Apr 9, 2014 at 9:18 AM, Fathi Boudra <fathi.boudra@linaro.org>
> > 
> > wrote:
> >> On 9 April 2014 18:02, Chris Larson <clarson@kergoth.com> wrote:
> >> > On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>
> >> > 
> >> > wrote:
> >> >> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
> >> >> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra
> >> >> > <fathi.boudra@linaro.org>
> >> >> > 
> >> >> > wrote:
> >> >> >>  do_install() {
> >> >> >> 
> >> >> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
> >> >> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
> >> >> >> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
> >> >> >> 
> >> >> >>  }
> >> >> > 
> >> >> > can you explain/document this change
> >> >> 
> >> >> sure. trace-cmd doesn't have a build system generated Makefile. It's
> >> >> hand written.
> >> >> To do the install properly, one has to pass prefix/plugin_dir.
> >> >> In addition, the previous command in the recipe doesn't do the right
> >> >> thing anymore (you'll end with duplicated prefix /usr/usr/).
> >> > 
> >> > You don't need to avoid the use of oe_runmake to pass variables in,
> >> > that's
> >> > what EXTRA_OEMAKE is for :) See
> >> > https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a
> >> > version
> >> > of this fix that uses it instead.
> >> 
> >> You don't need oe_runmake or EXTRA_OEMAKE to properly build and
> >> install the files in the right path either :)
> >> You can even drop inherit pkgconfig pythonnative since they aren't
> >> used. My version is also slightly shorter to achieve the same goal.
> > 
> > oe_runmake is the convention used by nearly every recipe in oe-core.
> > Breaking that convention for no good reason accomplishes nothing.
> 
> you can argue as you prefer. reality is that  using oe_runmake on this
> particular software accomplishes nothing.

It accomplishes as much as it does anywhere else. I don't see that this recipe 
needs to be special by not using it. In any case, you've run the recipe 
through oe-stylize to make it conform to OE style guidelines that that script 
handles, surely it's not a big thing to conform to this expected style as 
well?

Cheers,
Paul
Fathi Boudra April 15, 2014, 5:13 p.m. UTC | #9
On 15 April 2014 20:04, Paul Eggleton <paul.eggleton@linux.intel.com> wrote:
> On Wednesday 09 April 2014 22:25:31 Fathi Boudra wrote:
>> On 9 April 2014 22:15, Chris Larson <clarson@kergoth.com> wrote:
>> > On Wed, Apr 9, 2014 at 9:18 AM, Fathi Boudra <fathi.boudra@linaro.org>
>> >
>> > wrote:
>> >> On 9 April 2014 18:02, Chris Larson <clarson@kergoth.com> wrote:
>> >> > On Tue, Apr 8, 2014 at 10:16 AM, Fathi Boudra <fathi.boudra@linaro.org>
>> >> >
>> >> > wrote:
>> >> >> On 8 April 2014 20:05, Khem Raj <raj.khem@gmail.com> wrote:
>> >> >> > On Tue, Apr 8, 2014 at 7:00 AM, Fathi Boudra
>> >> >> > <fathi.boudra@linaro.org>
>> >> >> >
>> >> >> > wrote:
>> >> >> >>  do_install() {
>> >> >> >>
>> >> >> >> -       oe_runmake prefix="${prefix}" DESTDIR="${D}" install
>> >> >> >> +       ${MAKE} NO_PYTHON=1 prefix=${prefix}
>> >> >> >> plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
>> >> >> >>
>> >> >> >>  }
>> >> >> >
>> >> >> > can you explain/document this change
>> >> >>
>> >> >> sure. trace-cmd doesn't have a build system generated Makefile. It's
>> >> >> hand written.
>> >> >> To do the install properly, one has to pass prefix/plugin_dir.
>> >> >> In addition, the previous command in the recipe doesn't do the right
>> >> >> thing anymore (you'll end with duplicated prefix /usr/usr/).
>> >> >
>> >> > You don't need to avoid the use of oe_runmake to pass variables in,
>> >> > that's
>> >> > what EXTRA_OEMAKE is for :) See
>> >> > https://github.com/MentorEmbedded/meta-mentor/commit/4639877 for a
>> >> > version
>> >> > of this fix that uses it instead.
>> >>
>> >> You don't need oe_runmake or EXTRA_OEMAKE to properly build and
>> >> install the files in the right path either :)
>> >> You can even drop inherit pkgconfig pythonnative since they aren't
>> >> used. My version is also slightly shorter to achieve the same goal.
>> >
>> > oe_runmake is the convention used by nearly every recipe in oe-core.
>> > Breaking that convention for no good reason accomplishes nothing.
>>
>> you can argue as you prefer. reality is that  using oe_runmake on this
>> particular software accomplishes nothing.
>
> It accomplishes as much as it does anywhere else. I don't see that this recipe
> needs to be special by not using it. In any case, you've run the recipe
> through oe-stylize to make it conform to OE style guidelines that that script
> handles, surely it's not a big thing to conform to this expected style as
> well?

In that case, you might be able to replace ${MAKE} by oe_runmake in
the patchset and everybody will be happy.

> Cheers,
> Paul
>
> --
>
> Paul Eggleton
> Intel Open Source Technology Centre
diff mbox

Patch

diff --git a/meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb b/meta/recipes-kernel/trace-cmd/kernelshark_2.3.2.bb
similarity index 48%
rename from meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb
rename to meta/recipes-kernel/trace-cmd/kernelshark_2.3.2.bb
index 9268a50..f455707 100644
--- a/meta/recipes-kernel/trace-cmd/kernelshark_1.2.bb
+++ b/meta/recipes-kernel/trace-cmd/kernelshark_2.3.2.bb
@@ -3,27 +3,22 @@  LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
                     file://kernel-shark.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e"
 
-SRCREV = "7055ffd37beeb44714e86a4abc703f7e175a0db5"
-PR = "r3"
-PV = "1.2+git${SRCPV}"
+SRCREV = "79e08f8edb38c4c5098486caaa87ca90ba00f547"
+PV = "2.3.2"
 
 DEPENDS = "gtk+"
 RDEPENDS_${PN} = "trace-cmd"
 
-inherit pkgconfig pythonnative
-
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \
-           file://addldflags.patch \
-           file://make-docs-optional.patch \
-           file://blktrace-api-compatibility.patch"
+SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git;branch=trace-cmd-stable-v2.3"
 S = "${WORKDIR}/git"
 
-EXTRA_OEMAKE = "'CC=${CC}' 'AR=${AR}' 'prefix=${prefix}' gui"
-
 FILESPATH = "${FILE_DIRNAME}/trace-cmd"
 
 do_install() {
-	oe_runmake CC="${CC}" AR="${AR}" prefix="${prefix}" DESTDIR="${D}" install_gui
-	rm -rf ${D}${datadir}/trace-cmd
-	rmdir ${D}${datadir}
+	${MAKE} NO_PYTHON=1 prefix=${prefix} plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install_gui
+
+	# remove files already shipped in trace-cmd package
+	rm -f ${D}${bindir}/trace-cmd
+	rm -rf ${D}${libdir}/trace-cmd
+	rmdir ${D}${libdir}
 }
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch
deleted file mode 100644
index 14730db..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/addldflags.patch
+++ /dev/null
@@ -1,51 +0,0 @@ 
-trace-cmd: Cross-compile fixes for LDFLAGS and include path
-
-Add ability for the Makefile to respect LDFLAGS.
-Also remove hardcoded /usr/local/include include path.
-
-Upstream-Status: Accepted [Post 1.2: 5f576e9af7ad706774d9764a9ae3989376797c0e]
-
-Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-
----
- Makefile |    7 ++++---
- 1 file changed, 4 insertions(+), 3 deletions(-)
-
-Index: git/Makefile
-===================================================================
---- git.orig/Makefile
-+++ git/Makefile
-@@ -202,12 +202,13 @@ export Q VERBOSE
- TRACECMD_VERSION = $(TC_VERSION).$(TC_PATCHLEVEL).$(TC_EXTRAVERSION)
- KERNELSHARK_VERSION = $(KS_VERSION).$(KS_PATCHLEVEL).$(KS_EXTRAVERSION)
- 
--INCLUDES = -I. -I/usr/local/include $(CONFIG_INCLUDES)
-+INCLUDES = -I. $(CONFIG_INCLUDES)
- 
- include features.mk
- 
- # Set compile option CFLAGS if not set elsewhere
- CFLAGS ?= -g -Wall
-+LDFLAGS ?=
- 
- ifndef NO_PTRACE
- ifneq ($(call try-cc,$(SOURCE_PTRACE),),y)
-@@ -251,7 +252,7 @@ do_fpic_compile =					\
- 
- do_app_build =						\
- 	($(print_app_build)				\
--	$(CC) $^ -rdynamic -o $@ $(CONFIG_LIBS) $(LIBS))
-+	$(CC) $^ -rdynamic -o $@ $(LDFLAGS) $(CONFIG_LIBS) $(LIBS))
- 
- do_compile_shared_library =			\
- 	($(print_shared_lib_compile)		\
-@@ -263,7 +264,7 @@ do_compile_plugin_obj =				\
- 
- do_plugin_build =				\
- 	($(print_plugin_build)			\
--	$(CC) $(CFLAGS) -shared -nostartfiles -o $@ $<)
-+	$(CC) $(CFLAGS) $(LDFLAGS) -shared -nostartfiles -o $@ $<)
- 
- do_build_static_lib =				\
- 	($(print_static_lib_build)		\
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
deleted file mode 100644
index 0789e9f..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
+++ /dev/null
@@ -1,29 +0,0 @@ 
-trace-cmd: Add blktrace_api compatibility for TC_BARRIER
-
-Newer kernels replace TC_BARRIER with TC_FLUSH. Ensure trace-cmd
-can build regardless of the linux-kernel-headers version.
-
-Upstream-Status: Innapropriate [Stop gap]
-
-Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-
-diff --git a/plugin_blk.c b/plugin_blk.c
-index 9327b17..c8e5e1c 100644
---- a/plugin_blk.c
-+++ b/plugin_blk.c
-@@ -44,6 +44,15 @@ struct blk_data {
- 	unsigned short		pdu_len;
- };
- 
-+/*
-+ * Newer kernels don't define BLK_TC_BARRIER and have replaced it with
-+ * BLK_TC_FLUSH. In this case, define it here and report FLUSHES as BARRIERS as
-+ * a workaround, as described in:
-+ * http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=c09c47caedc9854d59378d6e34c989e51cfdd2b4
-+ */
-+#ifndef BLK_TC_BARRIER
-+#define BLK_TC_BARRIER 1<<2
-+#endif
- static void fill_rwbs(char *rwbs, int action, unsigned int bytes)
- {
- 	int i = 0;
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch
deleted file mode 100644
index 8402426..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/make-docs-optional.patch
+++ /dev/null
@@ -1,36 +0,0 @@ 
-Disable building docs until we have asciidocs available as a recipe.
-
-Upstream-Status: Inappropriate [Account for missing dependency, the lazy way]
-
-Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-
----
- Makefile |    8 ++++++--
- 1 file changed, 6 insertions(+), 2 deletions(-)
-
-Index: git/Makefile
-===================================================================
---- git.orig/Makefile
-+++ git/Makefile
-@@ -327,7 +327,9 @@ TARGETS = $(CMD_TARGETS) $(GUI_TARGETS)
- #    If you want kernelshark, then do:  make gui
- ###
- 
--all: all_cmd doc show_gui_make
-+# Make doc optional
-+#all: all_cmd doc show_gui_make
-+all: all_cmd show_gui_make
- 
- all_cmd: $(CMD_TARGETS)
- 
-@@ -503,7 +505,9 @@ install_python: $(PYTHON_SO_INSTALL) $(P
- install_cmd: all_cmd install_plugins install_python
- 	$(Q)$(call do_install,trace-cmd,$(bindir_SQ))
- 
--install: install_cmd install_doc
-+# Make doc optional
-+#install: install_cmd install_doc
-+install: install_cmd
- 	@echo "Note: to install the gui, type \"make install_gui\""
- 
- install_gui: install_cmd gui
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch
deleted file mode 100644
index 8fdeedb..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch
+++ /dev/null
@@ -1,61 +0,0 @@ 
-From a6e259b2cd43db3c0f69441f627a8cf214f88506 Mon Sep 17 00:00:00 2001
-From: Mark Asselstine <mark.asselstine@windriver.com>
-Date: Thu, 5 Apr 2012 15:19:44 -0400
-Subject: [PATCH] trace-cmd: Add checks for invalid pointers to fix segfaults
-
-Upstream-Status: Backport
-
-Running 'trace-cmd report' after running latency tracers will cause a
-segfault due to invalid pointers. Adding checks to ensure
-pointers/lists are initialized before attempting to use them prevents
-these segfaults.
-
-Link: http://lkml.kernel.org/r/1333653586-3379-2-git-send-email-mark.asselstine@windriver.com
-
-Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
-Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
----
- trace-input.c |   12 +++++++++---
- 1 file changed, 9 insertions(+), 3 deletions(-)
-
-diff --git a/trace-input.c b/trace-input.c
-index b6af1e6..5151c1e 100644
---- a/trace-input.c
-+++ b/trace-input.c
-@@ -695,7 +695,8 @@ static void __free_page(struct tracecmd_input *handle, struct page *page)
- 
- static void free_page(struct tracecmd_input *handle, int cpu)
- {
--	if (!handle->cpu_data[cpu].page)
-+	if (!handle->cpu_data || cpu >= handle->cpus ||
-+	    !handle->cpu_data[cpu].page)
- 		return;
- 
- 	__free_page(handle, handle->cpu_data[cpu].page);
-@@ -746,8 +747,12 @@ void tracecmd_record_ref(struct record *record)
- 
- static void free_next(struct tracecmd_input *handle, int cpu)
- {
--	struct record *record = handle->cpu_data[cpu].next;
-+	struct record *record;
-+
-+	if (!handle->cpu_data || cpu >= handle->cpus)
-+		return;
- 
-+	record = handle->cpu_data[cpu].next;
- 	if (!record)
- 		return;
- 
-@@ -2337,7 +2342,8 @@ void tracecmd_close(struct tracecmd_input *handle)
- 		/* The tracecmd_peek_data may have cached a record */
- 		free_next(handle, cpu);
- 		free_page(handle, cpu);
--		if (!list_empty(&handle->cpu_data[cpu].pages))
-+		if (handle->cpu_data &&
-+		    !list_empty(&handle->cpu_data[cpu].pages))
- 			warning("pages still allocated on cpu %d%s",
- 				cpu, show_records(&handle->cpu_data[cpu].pages));
- 	}
--- 
-1.7.10.4
-
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch
deleted file mode 100644
index 4c00c51..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch
+++ /dev/null
@@ -1,38 +0,0 @@ 
-From 356dee73d9ced3e019dea2883a7f357fd4664b3e Mon Sep 17 00:00:00 2001
-From: Mark Asselstine <mark.asselstine@windriver.com>
-Date: Thu, 5 Apr 2012 15:19:45 -0400
-Subject: [PATCH] trace-cmd: Do not call stop_threads() if doing latency
- tracing
-
-Upstream-Status: Backport
-
-If we are using a latency tracer we do not call start_threads() we
-should therefore not call stop_threads() if 'latency'. Attempting
-to call stop_threads() without first calling start_threads() will
-cause a segfault since pids will be uninitialized.
-
-Link: http://lkml.kernel.org/r/1333653586-3379-3-git-send-email-mark.asselstine@windriver.com
-
-Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
-Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
----
- trace-record.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/trace-record.c b/trace-record.c
-index fcec28b..1c56fa9 100644
---- a/trace-record.c
-+++ b/trace-record.c
-@@ -2216,7 +2216,8 @@ void trace_record (int argc, char **argv)
- 		}
- 
- 		disable_tracing();
--		stop_threads();
-+		if (!latency)
-+			stop_threads();
- 	}
- 
- 	for (cpu = 0; cpu < cpu_count; cpu++) {
--- 
-1.7.10.4
-
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch b/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch
deleted file mode 100644
index 724e1e8..0000000
--- a/meta/recipes-kernel/trace-cmd/trace-cmd/trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch
+++ /dev/null
@@ -1,96 +0,0 @@ 
-From d65740d61e7a4ea6d8d77237954b33dd18e3276c Mon Sep 17 00:00:00 2001
-From: Mark Asselstine <mark.asselstine@windriver.com>
-Date: Sun, 8 Apr 2012 11:38:45 -0400
-Subject: [PATCH] trace-cmd: Setting plugin to 'nop' clears data before it's
- recorded
-
-Upstream-Status: Backport
-
-commit e09a5db1a929ab668c273b87c4f0a32b81e1c21a
-[trace-cmd: Add trace-cmd record --date option]
-
-moved the call to disable_all() in trace_record() from after record_data()
-to before it. Unfortunately disable_all() sets 'nop' in 'current_tracer'
-which has the side affect of clearing 'trace', thus all the latency tracer
-reports are empty/useless. Here we make disable_all() optionally call
-set_plugin() thus, where we need to, we can delay the disabling of the tracer
-until we have had a chance to capture 'trace'. We have added this delayed
-behavior to trace_record() to fix the latency reports, for all other calls to
-disable_all() we continue to have set_plugin() called.
-
-Link: http://lkml.kernel.org/r/1333899525-6436-1-git-send-email-mark.asselstine@windriver.com
-
-Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
-Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
----
- trace-record.c |   16 ++++++++++------
- 1 file changed, 10 insertions(+), 6 deletions(-)
-
-diff --git a/trace-record.c b/trace-record.c
-index 1c56fa9..95d4a2a 100644
---- a/trace-record.c
-+++ b/trace-record.c
-@@ -897,11 +897,13 @@ static void disable_tracing(void)
- 	write_tracing_on(0);
- }
- 
--static void disable_all(void)
-+static void disable_all(int disable_tracer)
- {
- 	disable_tracing();
- 
--	set_plugin("nop");
-+	if (disable_tracer)
-+		set_plugin("nop");
-+
- 	reset_events();
- 
- 	/* Force close and reset of ftrace pid file */
-@@ -1573,7 +1575,7 @@ static void set_funcs(void)
- 	/* make sure we are filtering functions */
- 	if (func_stack) {
- 		if (!functions_filtered()) {
--			disable_all();
-+			disable_all(1);
- 			die("Function stack trace set, but functions not filtered");
- 		}
- 		save_option(FUNC_STACK_TRACE);
-@@ -1938,7 +1940,7 @@ void trace_record (int argc, char **argv)
- 				break;
- 			}
- 		}
--		disable_all();
-+		disable_all(1);
- 		set_buffer_size();
- 		exit(0);
- 	} else
-@@ -2147,7 +2149,7 @@ void trace_record (int argc, char **argv)
- 
- 	if (!extract) {
- 		fset = set_ftrace(!disable);
--		disable_all();
-+		disable_all(1);
- 
- 		/* Record records the date first */
- 		if (record && date)
-@@ -2227,7 +2229,7 @@ void trace_record (int argc, char **argv)
- 	}
- 
- 	if (!keep)
--		disable_all();
-+		disable_all(0);
- 
- 	printf("Kernel buffer statistics:\n"
- 	       "  Note: \"entries\" are the entries left in the kernel ring buffer and are not\n"
-@@ -2249,6 +2251,8 @@ void trace_record (int argc, char **argv)
- 	if (keep)
- 		exit(0);
- 
-+	set_plugin("nop");
-+
- 	/* If tracing_on was enabled before we started, set it on now */
- 	if (tracing_on_init_val)
- 		write_tracing_on(tracing_on_init_val);
--- 
-1.7.10.4
-
diff --git a/meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb b/meta/recipes-kernel/trace-cmd/trace-cmd_2.3.2.bb
similarity index 41%
rename from meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb
rename to meta/recipes-kernel/trace-cmd/trace-cmd_2.3.2.bb
index 74eafbb..eed1010 100644
--- a/meta/recipes-kernel/trace-cmd/trace-cmd_1.2.bb
+++ b/meta/recipes-kernel/trace-cmd/trace-cmd_2.3.2.bb
@@ -3,28 +3,16 @@  LICENSE = "GPLv2 & LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
                     file://trace-cmd.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e \
                     file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff \
-                    file://trace-input.c;beginline=5;endine=8;md5=6ad47cc2b03385d8456771eec5eeea0b"
+                    file://trace-input.c;beginline=5;endine=8;md5=dafd8a1cade30b847a8686dd3628cea4"
 
-SRCREV = "7055ffd37beeb44714e86a4abc703f7e175a0db5"
-PR = "r3"
-PV = "1.2+git${SRCPV}"
+SRCREV = "79e08f8edb38c4c5098486caaa87ca90ba00f547"
+PV = "2.3.2"
 
-inherit pkgconfig pythonnative
-
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \
-           file://addldflags.patch \
-           file://make-docs-optional.patch \
-           file://blktrace-api-compatibility.patch \
-           file://trace-cmd-Add-checks-for-invalid-pointers-to-fix-seg.patch \
-           file://trace-cmd-Do-not-call-stop_threads-if-doing-latency-.patch \
-           file://trace-cmd-Setting-plugin-to-nop-clears-data-before-i.patch \
-"
+SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git;branch=trace-cmd-stable-v2.3"
 S = "${WORKDIR}/git"
 
-EXTRA_OEMAKE = "'prefix=${prefix}'"
-
-FILES_${PN}-dbg += "${datadir}/trace-cmd/plugins/.debug/"
+FILES_${PN}-dbg += "${libdir}/trace-cmd/plugins/.debug/"
 
 do_install() {
-	oe_runmake prefix="${prefix}" DESTDIR="${D}" install
+	${MAKE} NO_PYTHON=1 prefix=${prefix} plugin_dir=${libdir}/trace-cmd/plugins DESTDIR=${D} install
 }