[RFC PATCH] [media] rc: filter out not allowed protocols when decoding

2012-08-31 Thread Du, Changbin
From: "Du, Changbin" Each rc-raw device has a property "allowed_protos" stored in structure ir_raw_event_ctrl. But it didn't work because all decoders would be called when decoding. This path makes only allowed protocol decoders been invoked. Signed-off-by: Du, Changb

[PATCH] dynamic_debug: add wildcard support to filter files/functions/modules

2013-07-25 Thread Du, Changbin
From: "Du, Changbin" This patch add wildcard '*'(matches zero or more characters) and '?' (matches one character) support when qurying debug flags. Now we can open debug messages using keywords. eg: 1. open debug logs in all usb drivers echo "file drivers

[Resend PATCH v2] usb: gadget: s3c-hsotg: fix core reset timeout failure

2012-07-23 Thread Du, Changbin
From: "Du, Changbin" The timeout values were 1000 and timeout issue occured many times on my s3c6410 Soc based board (mostly when booting whith USB cable not connected). This patch increase the values to 1 to guarantee the success of reset. Having set timeout to 1, I p

Re: [Resend PATCH] media: rc: ati_remote.c: code style and compile warning fixing

2012-07-06 Thread Du Changbin
gt; >*Added support for the "Lola" remote contributed by: > >*Seth Cohn > > + * Jul 2012: Du, Changbin > > + *Code style and compile warning fixing > > You shouldn't be changing the driver's autho

[PATCH v2] [media] rc: ati_remote.c: code style fixing

2012-07-07 Thread Du, Changbin
From: "Du, Changbin" changes: 1. wrap some lines that are longer than 80 characters. 2. remove local function prototype declarations which do not need. 3. replace TAB character with a space character in function comments. Signed-off-by: Du

Re: Does perf-annotate work correctly?

2017-10-16 Thread Du, Changbin
On Mon, Oct 16, 2017 at 11:28:53AM +0200, Jiri Olsa wrote: > On Fri, Oct 13, 2017 at 06:15:00PM +0800, Du, Changbin wrote: > > Hi Jiri, > > Sorry, missed you (but get_maintainer.pl doesn't list you). Here is ealier > > email. > > https://lkml.org/lkml/2017/9/12/1

Re: Does perf-annotate work correctly?

2017-10-16 Thread Du, Changbin
On Mon, Oct 16, 2017 at 11:30:51AM +0200, Jiri Olsa wrote: > On Fri, Oct 13, 2017 at 06:15:00PM +0800, Du, Changbin wrote: > > Hi Jiri, > > Sorry, missed you (but get_maintainer.pl doesn't list you). Here is ealier > > email. > > https://lkml.org/lkml/2017/9/12/1

Re: [PATCH 1/2] mm, thp: introduce dedicated transparent huge page allocation interfaces

2017-10-17 Thread Du, Changbin
Hi Khandual, Thanks for your review. On Tue, Oct 17, 2017 at 01:38:07PM +0530, Anshuman Khandual wrote: > On 10/16/2017 02:49 PM, changbin...@intel.com wrote: > > From: Changbin Du > > > > This patch introduced 4 new interfaces to allocate a prepared > > transparent huge page. > > - alloc_tran

Re: [PATCH 2/2] mm: rename page dtor functions to {compound,huge,transhuge}_page__dtor

2017-10-17 Thread Du, Changbin
Hi Khandual, > > long freed); > > bool isolate_huge_page(struct page *page, struct list_head *list); > > void putback_active_hugepage(struct page *page); > > -void free_huge_page(struct page *page); > > +void huge_page_dtor(struct page *page); > > void

Re: [Q] What about PCI mmio access alignment?

2017-05-28 Thread Du, Changbin
06:32:48PM +0300, Andy Shevchenko wrote: > On Thu, May 25, 2017 at 1:12 PM, Du, Changbin wrote: > > I have a basic quesion about the alignment when access PCI bar mmio space. > > Is > > the address accessed must be DW aligned and count must be DW aligned? > > I guess the

Re: [PATCH v2] tracing: Allocate mask_str buffer dynamically

2017-10-31 Thread Du, Changbin
Hi Rostedt, On Tue, Oct 31, 2017 at 12:19:58PM -0400, Steven Rostedt wrote: > On Thu, 26 Oct 2017 00:20:28 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > The default NR_CPUS can be very large, but actual possible nr_cpu_ids > > usually is very small. For my x86 distribution

Re: [PATCH] x86, build: Improve the isolinux searching of isoimage generation

2017-11-01 Thread Du, Changbin
Hi Ingo and Yamada, Thanks for your suggestions. I'll have a try though I am not familiar with kbuild system. On Wed, Nov 01, 2017 at 12:17:50PM +0900, Masahiro Yamada wrote: > 2017-10-31 18:39 GMT+09:00 Ingo Molnar : > > > > * changbin...@intel.com wrote: > > > >> From: Changbin Du > >> > >> R

Re: [PATCH] tracing: Allocate mask_str buffer dynamically

2017-10-25 Thread Du, Changbin
On Wed, Oct 25, 2017 at 07:24:36PM +0800, changbin...@intel.com wrote: > From: Changbin Du > > The default NR_CPUS can be very large, but actual possible nr_cpu_ids > usually is very small. For my x86 distribution, the NR_CPUS is 8192 and > nr_cpu_ids is 4. About 2 pages are wasted. > > Most mac

Re: [PATCH 1/4] x86, build: Fact out fdimage/isoimage generation commands to standalone script

2017-11-05 Thread Du, Changbin
On Sun, Nov 05, 2017 at 10:32:08AM +0100, Ingo Molnar wrote: > > A few spelling fixes: > > in the title: > > s/Fact out > /Factor out > > * changbin...@intel.com wrote: > > > From: Changbin Du > > > > The build message for fdimage/isoimage are pretty unstructured. The raw > > shell command

Re: [PATCH 2/4] x86, build: Add new paths for isolinux.bin and ldlinux.c32

2017-11-05 Thread Du, Changbin
Hi Ingo, On Sun, Nov 05, 2017 at 10:33:53AM +0100, Ingo Molnar wrote: > > * changbin...@intel.com wrote: > > > From: Changbin Du > > > > Recently I failed to build isoimage target, because the path of isolinux.bin > > changed to /usr/xxx/ISOLINUX/isolinux.bin, as well as ldlinux.c32 which > >

Re: [PATCH 1/2] mm, thp: introduce dedicated transparent huge page allocation interfaces

2017-10-18 Thread Du, Changbin
Hi Hocko, On Tue, Oct 17, 2017 at 12:20:52PM +0200, Michal Hocko wrote: > [CC Kirill] > > On Mon 16-10-17 17:19:16, changbin...@intel.com wrote: > > From: Changbin Du > > > > This patch introduced 4 new interfaces to allocate a prepared > > transparent huge page. > > - alloc_transhuge_page_vm

Re: [PATCH 1/2] mm, thp: introduce dedicated transparent huge page allocation interfaces

2017-10-18 Thread Du, Changbin
On Tue, Oct 17, 2017 at 02:12:46PM +0300, Kirill A. Shutemov wrote: > On Mon, Oct 16, 2017 at 05:19:16PM +0800, changbin...@intel.com wrote: > > @@ -501,6 +501,45 @@ void prep_transhuge_page(struct page *page) > > set_compound_page_dtor(page, TRANSHUGE_PAGE_DTOR); > > } > > > > +struct page

Re: [PATCH 0/2] mm, thp: introduce dedicated transparent huge page allocation interfaces

2017-10-18 Thread Du, Changbin
Hi Morton, On Tue, Oct 17, 2017 at 04:28:16PM -0700, Andrew Morton wrote: > On Mon, 16 Oct 2017 17:19:15 +0800 changbin...@intel.com wrote: > > > The first one introduce new interfaces, the second one kills naming > > confusion. > > The aim is to remove duplicated code and simplify transparent hu

[RESEND PATCH v2] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-08-30 Thread Du, Changbin
>From 08df419517694c4dd9ff328f5644b46a99c2999e Mon Sep 17 00:00:00 2001 From: "Du, Changbin" Date: Thu, 23 Jul 2015 20:08:04 +0800 Subject: [PATCH v2] usb/gadget: make composite gadget meet usb compliance for vbus draw USB-IF compliance requirement limits the vbus current accordi

RE: [RESEND PATCH v2] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-08-31 Thread Du, Changbin
I am sorry, I forget to remove them. It is generated by git and I send the patch with outlook. I will use git-send-email instead next time if my email account work. Regards Du, Changbin > -Original Message- > From: 'Greg Kroah-Hartman' [mailto:gre...@linuxfoundation.org

Re: [PATCH 3/3] tracing: don't set parser->cont if it has reached the end of input buffer

2018-01-11 Thread Du, Changbin
Hi Rostedt, On Tue, Jan 09, 2018 at 11:19:36PM -0500, Steven Rostedt wrote: > On Wed, 10 Jan 2018 11:18:23 +0800 > "Du, Changbin" wrote: > > > write(3, "abcdefg", 7) > > > > > > From my point of view, the above isn't done writing the

Re: [PATCH] perf ftrace: Fix the buffer size in __write_tracing_file

2018-01-07 Thread Du, Changbin
Hi Olsa, What about this fix now? Thanks! On Tue, Dec 26, 2017 at 05:26:56PM +0800, changbin...@intel.com wrote: > From: Changbin Du > > The terminal character '\0' should take into account as size of the string > buffer. Without this fix, the '--graph-funcs', '--nograph-funcs' and > '--trace-fu

Re: [PATCH v3 0/3] tracing: Fix the parser when processing strings w/ or w/o terminated '\0'

2018-01-16 Thread Du, Changbin
On Tue, Jan 16, 2018 at 12:42:26PM -0500, Steven Rostedt wrote: > On Tue, 16 Jan 2018 17:02:27 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > I found there are some problems in the tracing parser when I investiage the > > root > > cause of issues mentioned in below patch.

Re: [PATCH v3 0/3] tracing: Fix the parser when processing strings w/ or w/o terminated '\0'

2018-01-16 Thread Du, Changbin
On Wed, Jan 17, 2018 at 02:45:24PM +0900, Namhyung Kim wrote: > Hello, > > On Wed, Jan 17, 2018 at 12:54:34PM +0800, Du, Changbin wrote: > > On Tue, Jan 16, 2018 at 12:42:26PM -0500, Steven Rostedt wrote: > > > On Tue, 16 Jan 2018 17:02:27 +0800 > >

Re: [PATCH] perf ftrace: Fix the buffer size in __write_tracing_file

2018-01-08 Thread Du, Changbin
On Mon, Jan 08, 2018 at 03:34:57PM +0100, Jiri Olsa wrote: > On Mon, Jan 08, 2018 at 11:05:12AM +0800, Du, Changbin wrote: > > Hi Olsa, > > What about this fix now? Thanks! > > > > On Tue, Dec 26, 2017 at 05:26:56PM +0800, changbin...@intel.com wrote: > > >

Re: [PATCH 1/3] tracing: detect the string termination character when parsing user input string

2018-01-09 Thread Du, Changbin
hi Rostedt, On Tue, Jan 09, 2018 at 05:54:34PM -0500, Steven Rostedt wrote: > On Tue, 9 Jan 2018 17:55:46 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > The usersapce can give a '\0' terminated C string or even has '\0' at the > > middle of input buffer. We need handle bo

Re: [PATCH 2/3] tracing: make sure the parsed string always terminates with '\0'

2018-01-09 Thread Du, Changbin
On Tue, Jan 09, 2018 at 06:02:58PM -0500, Steven Rostedt wrote: > On Tue, 9 Jan 2018 17:55:47 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > The parser parse every string into parser.buffer. And some of the callers > > assume that parser.buffer contains a C string. So it i

Re: [PATCH 3/3] tracing: don't set parser->cont if it has reached the end of input buffer

2018-01-09 Thread Du, Changbin
On Tue, Jan 09, 2018 at 06:12:41PM -0500, Steven Rostedt wrote: > On Tue, 9 Jan 2018 17:55:48 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > We should not set parser->cont if it has reached the end of input buffer. > > And since some callers (like ftrace_graph_write()) tre

Re: [PATCH 3/3] tracing: don't set parser->cont if it has reached the end of input buffer

2018-01-13 Thread Du, Changbin
On Fri, Jan 12, 2018 at 10:31:08AM -0500, Steven Rostedt wrote: [...] > > Thanks, so now I unstand why below corner case. The userspace try to set the > > filter with a unrecognized symbole name (e.g "abcdefg"). > > open("/sys/kernel/debug/tracing/set_ftrace_filter", O_WRONLY|O_TRUNC) = 3 > > write

Re: [PATCH 2/3] tracing: make sure the parsed string always terminates with '\0'

2018-01-15 Thread Du, Changbin
On Tue, Jan 09, 2018 at 11:10:22PM -0500, Steven Rostedt wrote: > On Wed, 10 Jan 2018 11:02:06 +0800 > "Du, Changbin" wrote: > > > On Tue, Jan 09, 2018 at 06:02:58PM -0500, Steven Rostedt wrote: > > > On Tue, 9 Jan 2018 17:55:47 +0800 > > > changbi

Re: [PATCH v2 1/3] tracing: detect the string termination character when parsing user input string

2018-01-15 Thread Du, Changbin
Hi Rostedt, Thanks for your polish, let me update commit msg with your words. On Mon, Jan 15, 2018 at 06:20:00PM -0500, Steven Rostedt wrote: > On Mon, 15 Jan 2018 19:41:12 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > The usersapce can give a '\0' terminated C string in

Re: [RESEND PATCH] perf sched map: re-annotate shortname if thread comm changed

2018-03-05 Thread Du, Changbin
I just done final version, please check v2. Thanks for your comments! On Mon, Mar 05, 2018 at 11:37:54PM +0100, Jiri Olsa wrote: > On Mon, Mar 05, 2018 at 03:11:36PM +0800, Du, Changbin wrote: > > SNIP > > > > > on the other hand it's simple enough and looks > &

Re: [PATCH v2 0/2] perf sched map: re-annotate shortname if thread comm changed

2018-03-06 Thread Du, Changbin
On Tue, Mar 06, 2018 at 11:17:07AM -0300, Arnaldo Carvalho de Melo wrote: > Em Tue, Mar 06, 2018 at 08:53:02AM +0100, Jiri Olsa escreveu: > > On Tue, Mar 06, 2018 at 11:37:35AM +0800, changbin...@intel.com wrote: > > > From: Changbin Du > > > > > > v2: > > > o add a patch to move thread::shortn

Re: [PATCH 4/4] selftests/bpf: fix compiling errors

2018-03-26 Thread Du, Changbin
On Mon, Mar 26, 2018 at 07:55:13AM -0700, Alexei Starovoitov wrote: > On Mon, Mar 26, 2018 at 05:23:28PM +0800, changbin...@intel.com wrote: > > Signed-off-by: Changbin Du > > --- > > tools/testing/selftests/bpf/Makefile | 5 +++-- > > 1 file changed, 3 insertions(+), 2 deletions(-) > > > > diff

Re: [PATCH 4/4] selftests/bpf: fix compiling errors

2018-03-26 Thread Du, Changbin
Hi Starovoitov, This one does have the issue you mentioned. [PATCH 2/4] selftests/gpio: fix paths in Makefile And can be fixed by: --- a/tools/testing/selftests/gpio/Makefile +++ b/tools/testing/selftests/gpio/Makefile @@ -1,5 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 +OUTPUT ?= $(shell pwd)

Re: [PATCH 4/4] selftests/bpf: fix compiling errors

2018-03-26 Thread Du, Changbin
On Mon, Mar 26, 2018 at 08:02:30PM -0700, Alexei Starovoitov wrote: > On Tue, Mar 27, 2018 at 10:20:10AM +0800, Du, Changbin wrote: > > On Mon, Mar 26, 2018 at 07:55:13AM -0700, Alexei Starovoitov wrote: > > > On Mon, Mar 26, 2018 at 05:23:28PM +0800, changbin...@intel.com wro

Re: [PATCH 4/4] selftests/bpf: fix compiling errors

2018-03-27 Thread Du, Changbin
On Tue, Mar 27, 2018 at 10:52:57AM +0200, Daniel Borkmann wrote: > On 03/27/2018 05:06 AM, Du, Changbin wrote: > > On Mon, Mar 26, 2018 at 08:02:30PM -0700, Alexei Starovoitov wrote: > >> On Tue, Mar 27, 2018 at 10:20:10AM +0800, Du, Changbin wrote: > >>> On Mon, Ma

Re: [PATCH 4/4] selftests/bpf: fix compiling errors

2018-03-27 Thread Du, Changbin
On Tue, Mar 27, 2018 at 11:52:27AM +0200, Daniel Borkmann wrote: > On 03/27/2018 11:00 AM, Du, Changbin wrote: > > On Tue, Mar 27, 2018 at 10:52:57AM +0200, Daniel Borkmann wrote: > >> On 03/27/2018 05:06 AM, Du, Changbin wrote: > >>> On Mon, Mar 26, 2018 at 08:02:

Re: [PATCH] Documentation: fix reST markup error in driver-api/usb/typec.rst

2018-04-08 Thread Du, Changbin
On Sun, Apr 08, 2018 at 09:19:58AM +0200, Greg KH wrote: > On Sun, Apr 08, 2018 at 10:47:12AM +0800, changbin...@intel.com wrote: > > From: Changbin Du > > > > There is an format error in driver-api/usb/typec.rst that breaks sphinx > > docs building. > > > > reST markup error: > > /home/changbin

Re: [PATCH 00/17] Include linux trace docs to Sphinx TOC tree

2018-03-07 Thread Du, Changbin
On Wed, Mar 07, 2018 at 10:46:49AM -0700, Jonathan Corbet wrote: > On Tue, 27 Feb 2018 17:43:37 -0500 > Steven Rostedt wrote: > > > On Tue, 27 Feb 2018 17:34:22 +0800 > > "Du, Changbin" wrote: > > > > > Ten days past, will you accept this

Re: [PATCH] scripts/faddr2line: show the code context

2018-06-03 Thread Du, Changbin
On Wed, May 30, 2018 at 08:01:48AM +1000, NeilBrown wrote: > On Tue, May 29 2018, Peter Zijlstra wrote: > > > On Tue, May 29, 2018 at 12:07:10PM -0500, Josh Poimboeuf wrote: > >> Yeah, this change really should have been an optional arg. It hurt the > >> readability and compactness of the output.

Re: [PATCH] scripts/faddr2line: show the code context

2018-06-03 Thread Du, Changbin
On Tue, May 29, 2018 at 06:03:32PM +0200, Peter Zijlstra wrote: > On Mon, Mar 19, 2018 at 03:23:25PM +0800, changbin...@intel.com wrote: > > From: Changbin Du > > > > Inspired by gdb command 'list', show the code context of target lines. > > Here is a example: > > > > $ scripts/faddr2line vmlinu

Re: kernel BUG at arch/x86/kvm/x86.c:LINE! (2)

2018-10-10 Thread Du Changbin
000 DR6: fffe0ff0 DR7: 0400 --- This bug is generated by a bot. It may contain errors. See https://goo.gl/tpsmEJ for more information about syzbot. syzbot engineers can be reached at syzkal...@googlegroups.com. syzbot will keep track of this bug report. See: https://go

[PATCH] scripts/gdb: fix lx-version for gdb 7.3-

2018-10-16 Thread Du Changbin
8 gdb 7.4 seems to be no such issue. Signed-off-by: Du Changbin --- scripts/gdb/linux/proc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/gdb/linux/proc.py b/scripts/gdb/linux/proc.py index 086d27223c0c..0aebd7565b03 100644 --- a/scripts/gdb/linux/proc.py +++ b/scripts

[PATCH v2] scripts/gdb: fix lx-version for gdb 7.3-

2018-10-17 Thread Du Changbin
2018 gdb 7.4 seems to be no such issue. Signed-off-by: Du Changbin --- scripts/gdb/linux/proc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/gdb/linux/proc.py b/scripts/gdb/linux/proc.py index 086d27223c0c..0aebd7565b03 100644 --- a/scripts/gdb/linux/proc.py +++

Re: [PATCH] PCI: make pci_size() return real size

2018-10-17 Thread Du Changbin
Hi Bjorn. Have you checked this little improvment? The idea here is that this is not a hotspot, so readbility matters than trick. Thanks! On Sat, Oct 13, 2018 at 08:49:19AM +0800, changbin...@gmail.com wrote: > From: Du Changbin > > Currently, the pci_size() function actually retur

[PATCH v3] scripts/gdb: fix lx-version

2018-10-17 Thread Du Changbin
u3)) #21 SMP Sat Sep 1 21:43:30 CST 2018 Signed-off-by: Du Changbin --- scripts/gdb/linux/proc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/gdb/linux/proc.py b/scripts/gdb/linux/proc.py index 086d27223c0c..0aebd7565b03 100644 --- a/scripts/gdb/linux/proc.py +++

[PATCH 1/4] x86/mm: surround level4_kernel_pgt with #ifdef CONFIG_X86_5LEVEL...#endif

2018-10-18 Thread Du Changbin
From: Changbin Du The level4_kernel_pgt is only defined when X86_5LEVEL is enabled. So surround level4_kernel_pgt with #ifdef CONFIG_X86_5LEVEL...#endif to make code correct. Signed-off-by: Changbin Du Acked-by: Steven Rostedt (VMware) --- arch/x86/include/asm/pgtable_64.h | 2 ++ arch/x86/k

[PATCH 2/4] kernel hacking: new config NO_AUTO_INLINE to disable compiler auto-inline optimizations

2018-10-18 Thread Du Changbin
From: Changbin Du This patch add a new kernel hacking option NO_AUTO_INLINE. Selecting this option will prevent the compiler from optimizing the kernel by auto-inlining functions not marked with the inline keyword. With this option, only functions explicitly marked with "inline" will be inlined.

[PATCH 0/4] kernel hacking: GCC optimization for better debug experience (-Og)

2018-10-18 Thread Du Changbin
Hi all, I have posted this series several months ago but interrupted by personal affairs. Now I get time to complete this task. Thanks for all of the reviewers. I know some kernel developers was searching for a method to dissable GCC optimizations, probably they want to apply GCC '-O0' option. But

[PATCH 4/4] kernel hacking: new config CC_OPTIMIZE_FOR_DEBUGGING to apply GCC -Og optimization

2018-10-18 Thread Du Changbin
From: Changbin Du This will apply GCC '-Og' optimization level which is supported since GCC 4.8. This optimization level offers a reasonable level of optimization while maintaining fast compilation and a good debugging experience. It is similar to '-O1' while perferring to keep debug ability over

[PATCH 3/4] ARM: mm: fix build error in fix_to_virt with CONFIG_CC_OPTIMIZE_FOR_DEBUGGING

2018-10-18 Thread Du Changbin
From: Changbin Du With '-Og' optimization level, GCC would not optimize a count for a loop as a constant value. But BUILD_BUG_ON() only accept compile-time constant values. Let's use __fix_to_virt() to avoid the error. arch/arm/mm/mmu.o: In function `fix_to_virt': /home/changbin/work/linux/./inc

Re: [PATCH 2/4] kernel hacking: new config NO_AUTO_INLINE to disable compiler auto-inline optimizations

2018-10-18 Thread Du Changbin
On Thu, Oct 18, 2018 at 05:57:56PM +0100, Robin Murphy wrote: > On 18/10/18 17:25, Du Changbin wrote: > > From: Changbin Du > > > > This patch add a new kernel hacking option NO_AUTO_INLINE. Selecting > > this option will prevent the compiler from optimizing the

Re: [PATCH 2/4] kernel hacking: new config NO_AUTO_INLINE to disable compiler auto-inline optimizations

2018-10-18 Thread Du Changbin
On Thu, Oct 18, 2018 at 12:59:48PM -0400, Steven Rostedt wrote: > On Thu, 18 Oct 2018 16:25:46 + > Du Changbin wrote: > > > From: Changbin Du > > > > This patch add a new kernel hacking option NO_AUTO_INLINE. Selecting > > this option will prevent the compi

[PATCH v2 0/4] kernel hacking: GCC optimization for better debug experience (-Og)

2018-10-19 Thread Du Changbin
\ make -j8 >/dev/null Performance counter stats for 'make -j8' (5 runs): 233.574187771 seconds time elapsed ( +- 0.19% ) Du Changbin (4): x86/mm: surround level4_kernel_pgt with #ifdef CONFIG_X86_5LEVEL...#endif kernel hacking

[PATCH v2 1/4] x86/mm: surround level4_kernel_pgt with #ifdef CONFIG_X86_5LEVEL...#endif

2018-10-19 Thread Du Changbin
The level4_kernel_pgt is only defined when X86_5LEVEL is enabled. So surround level4_kernel_pgt with #ifdef CONFIG_X86_5LEVEL...#endif to make code correct. Signed-off-by: Du Changbin Acked-by: Steven Rostedt (VMware) --- arch/x86/include/asm/pgtable_64.h | 2 ++ arch/x86/kernel/head64.c

[PATCH v2 2/4] kernel hacking: new config NO_AUTO_INLINE to disable compiler auto-inline optimizations

2018-10-19 Thread Du Changbin
will allow the function tracer to trace more functions because it only traces functions that the compiler has not inlined. Signed-off-by: Du Changbin Acked-by: Steven Rostedt (VMware) --- Makefile | 6 ++ lib/Kconfig.debug | 17 + 2 files changed, 23 insertions(+) di

[PATCH v2 3/4] ARM: mm: fix build error in fix_to_virt with CONFIG_CC_OPTIMIZE_FOR_DEBUGGING

2018-10-19 Thread Du Changbin
/include/asm-generic/fixmap.h:31: undefined reference to `__compiletime_assert_31' Makefile:1051: recipe for target 'vmlinux' failed make: *** [vmlinux] Error 1 Signed-off-by: Du Changbin Acked-by: Steven Rostedt (VMware) --- arch/arm/mm/mmu.c | 2 +- 1 file changed, 1 insertion(+

[PATCH v2 4/4] kernel hacking: new config CC_OPTIMIZE_FOR_DEBUGGING to apply GCC -Og optimization

2018-10-19 Thread Du Changbin
>/dev/null; \ make clean >/dev/null 2>&1; \ sync'\ \ make -j8 >/dev/null Performance counter stats for 'make -j8' (5 runs): 233.574187771 seconds time ela

[PATCH] usb: gadget: composite: enable BESL support

2015-04-28 Thread Du, Changbin
be enabled if LPM is enabled. This helps with USB30CV TD 9.21 LPM L1 Suspend Resume Test. Cc: # 3.14 Signed-off-by: Felipe Balbi Signed-off-by: Du, Changbin --- Hi, This patch was introduced on v3.18. However the issue fixed already existed on v3.14 and v3.14 is a long term support version. So prop

RE: [PATCH] usb: gadget: composite: enable BESL support

2015-04-28 Thread Du, Changbin
obably going to backport to > 3.10 and 3.14. When asking for backports, don't consider only your project, > think about the kernel/stable releases as a whole. > > BTW, that should be v3.1+, the + tells the Stable team that from v3.1 forward, > all kernels need the backport. >

[PATCH v2] usb: gadget: composite: enable BESL support

2015-04-28 Thread Du, Changbin
be enabled if LPM is enabled. This helps with USB30CV TD 9.21 LPM L1 Suspend Resume Test. Cc: # 3.1+: a661593: usb: enable BESL support Signed-off-by: Felipe Balbi Signed-off-by: Du, Changbin --- Hi, This patch was introduced on v3.18. However the issue fixed already existed on v3.1. Thank Balbi

[PATCH v3] usb: gadget: composite: enable BESL support

2015-04-29 Thread Du, Changbin
wer Management (USB2-LPM-Errata-final.pdf), BESL must be enabled if LPM is enabled. This helps with USB30CV TD 9.21 LPM L1 Suspend Resume Test. Signed-off-by: Felipe Balbi Signed-off-by: Du, Changbin --- Hi, This patch was introduced on v3.18. However the issue fixed already existed on v3.1. Th

[PATCH v4] usb: gadget: composite: enable BESL support

2015-04-29 Thread Du, Changbin
wer Management (USB2-LPM-Errata-final.pdf), BESL must be enabled if LPM is enabled. This helps with USB30CV TD 9.21 LPM L1 Suspend Resume Test. Cc: # 3.1+ Signed-off-by: Felipe Balbi Signed-off-by: Du, Changbin --- Hi, This patch was introduced on v3.18. However the issue fixed already existed

Re: [PATCH v2] tracing/power: Polish the tracepoints cpu_idle and cpu_frequency

2018-02-28 Thread Du, Changbin
On Wed, Feb 28, 2018 at 10:14:41AM +0100, Rafael J. Wysocki wrote: > On 2/28/2018 3:45 AM, Du, Changbin wrote: > > On Tue, Feb 27, 2018 at 05:39:38PM -0500, Steven Rostedt wrote: > > > On Tue, 27 Feb 2018 17:35:27 +0800 > > > "Du, Changbin" wrote: > >

Re: [PATCH] perf trace: remove redundant ')'

2018-04-03 Thread Du, Changbin
On Tue, Apr 03, 2018 at 04:19:07PM -0300, Arnaldo Carvalho de Melo wrote: > Em Wed, Mar 28, 2018 at 03:26:31PM +0800, Du, Changbin escreveu: > > Hi Arnaldo, > > Just a kind reminder. Hope you didn't forget this. > > Ok, applied. > > - Arnaldo > Got it, thanks!

Re: [PATCH v2 1/4] selftests/Makefile: append a slash to env variable OUTPUT

2018-03-27 Thread Du, Changbin
On Tue, Mar 27, 2018 at 03:19:26PM -0600, Shuah Khan wrote: > On 03/26/2018 09:11 PM, changbin...@intel.com wrote: > > From: Changbin Du > > > > The tools/build/Makefile.build use 'OUTPUT' variable as below example: > > objprefix:= $(subst ./,,$(OUTPUT)$(dir)/) > > > > So it requires the 'OU

Re: [PATCH] perf trace: remove redundant ')'

2018-03-28 Thread Du, Changbin
Hi Arnaldo, Just a kind reminder. Hope you didn't forget this. On Fri, Mar 16, 2018 at 09:50:45AM -0300, Arnaldo Carvalho de Melo wrote: > Em Fri, Mar 16, 2018 at 03:51:09PM +0800, Du, Changbin escreveu: > > Hi Arnaldo, How about this simple one? Thanks. > > > > On

Re: [PATCH 0/5] kernel hacking: GCC optimization for debug experience (-Og)

2018-05-02 Thread Du, Changbin
On Wed, May 02, 2018 at 09:33:15AM +0200, Ingo Molnar wrote: > > * changbin...@intel.com wrote: > > > Comparison of system performance: a bit drop. > > > > w/o CONFIG_DEBUG_EXPERIENCE > > $ time make -j4 > > real6m43.619s > > user19m5.160s > > sys 2m20.287s > >

Re: [PATCH 2/5] regulator: add dummy of_find_regulator_by_node

2018-05-02 Thread Du, Changbin
On Wed, May 02, 2018 at 05:40:36AM +0900, Mark Brown wrote: > On Tue, May 01, 2018 at 09:00:11PM +0800, changbin...@intel.com wrote: > > From: Changbin Du > > > > If device tree is not enabled, of_find_regulator_by_node() should have > > a dummy function since the function call is still there. >

Re: [PATCH 4/5] kernel hacking: new config DEBUG_EXPERIENCE to apply GCC -Og optimization

2018-05-02 Thread Du, Changbin
On Tue, May 01, 2018 at 08:25:27AM -0700, Randy Dunlap wrote: > Good morning. > > On 05/01/2018 06:00 AM, changbin...@intel.com wrote: > > From: Changbin Du > > > > > > Signed-off-by: Changbin Du > > --- > > Makefile | 4 > > include/linux/compiler-gcc.h | 2 +- > >

Re: [PATCH 3/5] kernel hacking: new config NO_AUTO_INLINE to disable compiler atuo-inline optimizations

2018-05-02 Thread Du, Changbin
On Tue, May 01, 2018 at 10:54:20AM -0400, Steven Rostedt wrote: > On Tue, 1 May 2018 21:00:12 +0800 > changbin...@intel.com wrote: > > > From: Changbin Du > > > > This patch add a new kernel hacking option NO_AUTO_INLINE. Selecting > > this option will make compiler not auto-inline kernel funct

Re: [PATCH v5 2/4] kernel hacking: new config NO_AUTO_INLINE to disable compiler auto-inline optimizations

2018-06-07 Thread Du, Changbin
Hi, On Thu, Jun 07, 2018 at 09:47:18AM +0530, Viresh Kumar wrote: > +Greg/Alex, > > @Fegguang/build-bot: I do see mention of Greg and /me in your initial email's > body saying TO: Viresh, CC: Greg, but I don't see any of us getting cc'd in > your > email. Bug ? > > On 06-06-18, 14:26, Steven Ros

Re: [PATCH] iommu/vt-d: fix shift-out-of-bounds in bug checking

2018-04-26 Thread Du, Changbin
Hello, any reviewer? Thanks! On Fri, Apr 20, 2018 at 01:29:55PM +0800, changbin...@intel.com wrote: > From: Changbin Du > > It allows to flush more than 4GB of device TLBs. So the mask should be > 64bit wide. UBSAN captured this fault as below. > > [3.760024] >

[PATCH v2] dynamic_debug: add wildcard support to filter files/functions/modules

2013-10-28 Thread Du, Changbin
From: "Du, Changbin" This patch add wildcard '*'(matches zero or more characters) and '?' (matches one character) support when qurying debug flags. Now we can open debug messages using keywords. eg: 1. open debug logs in all usb drivers echo "file drivers

[PATCH v3] dynamic_debug: add wildcard support to filter files/functions/modules

2013-10-29 Thread Du, Changbin
From: "Du, Changbin" This patch add wildcard '*'(matches zero or more characters) and '?' (matches one character) support when qurying debug flags. Now we can open debug messages using keywords. eg: 1. open debug logs in all usb drivers echo "file drivers

[PATCH v4 1/2] dynamic_debug: add wildcard support to filter files/functions/modules

2013-10-30 Thread Du, Changbin
From: "Du, Changbin" This patch add wildcard '*'(matches zero or more characters) and '?' (matches one character) support when qurying debug flags. Now we can open debug messages using keywords. eg: 1. open debug logs in all usb drivers echo "file drivers

[PATCH v4 2/2] dynamic-debug-howto.txt: update since new wildcard support

2013-10-30 Thread Du, Changbin
From: "Du, Changbin" Add the usage of using new feature wildcard support. Signed-off-by: Du, Changbin --- Documentation/dynamic-debug-howto.txt | 9 + 1 file changed, 9 insertions(+) diff --git a/Documentation/dynamic-debug-howto.txt b/Documentation/dynamic-debug-howto

[PATCH v5 0/3] add wildcard support for dynamic debug

2013-11-16 Thread Du, Changbin
From: "Du, Changbin" These patches are to make it easier to filter kernel debug logs which we want. Whith wildcard support, below command can enable all usb debug logs: #echo "file drivers/usb/* +p" > /dynamic_debug/control This patch only enables two wildcard: &#x

[PATCH v5 1/3] lib/parser.c: add match_wildcard function

2013-11-16 Thread Du, Changbin
From: "Du, Changbin" match_wildcard function is a simple implementation of wildcard matching algorithm. It only supports two usual wildcardes: '*' - matches zero or more characters '?' - matches one character This algorithm is safe since it's o

[PATCH v5 2/3] dynamic_debug: add wildcard support to filter files/functions/modules

2013-11-16 Thread Du, Changbin
From: "Du, Changbin" Add wildcard '*'(matches zero or more characters) and '?' (matches one character) support when qurying debug flags. Now we can open debug messages using keywords. eg: 1. open debug logs in all usb drivers echo "file drivers/usb/* +p

[PATCH v5 3/3] dynamic-debug-howto.txt: update since new wildcard support

2013-11-16 Thread Du, Changbin
From: "Du, Changbin" Add the usage of using new feature wildcard support. Signed-off-by: Du, Changbin --- Documentation/dynamic-debug-howto.txt | 9 + 1 file changed, 9 insertions(+) diff --git a/Documentation/dynamic-debug-howto.txt b/Documentation/dynamic-debug-howto

[PATCH] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-07-23 Thread Du, Changbin
>From 0a8e0d63a9887735c6782d7b0c15c2c1fdf1952a Mon Sep 17 00:00:00 2001 From: "Du, Changbin" Date: Thu, 23 Jul 2015 20:08:04 +0800 Subject: [PATCH] usb/gadget: make composite gadget meet usb compliance for vbus draw USB-IF compliance requirement limits the vbus current accordi

RE: [PATCH] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-07-23 Thread Du, Changbin
Thanks, Pietrasiewicz. > From: Andrzej Pietrasiewicz [mailto:andrze...@samsung.com] > W dniu 23.07.2015 o 14:34, Du, Changbin pisze: > >>From 0a8e0d63a9887735c6782d7b0c15c2c1fdf1952a Mon Sep 17 00:00:00 > > void composite_disconnect(struct usb_gadget *gadget) &

RE: [PATCH] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-07-24 Thread Du, Changbin
Thanks for explanation. I am agree with you that separate changes into two patches. Will send out new patch soon. Regards Du, Changbin > From: Andrzej Pietrasiewicz [mailto:andrze...@samsung.com] > Hi, > > W dniu 24.07.2015 o 06:11, Du, Changbin pisze: > > Thanks, Pietra

RE: [PATCH] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-07-27 Thread Du, Changbin
> > From: Andrzej Pietrasiewicz [mailto:andrze...@samsung.com] Hi, > > > > What I mean is that in my opinion it should be done in a separate > > patch, because the newly introduced USB_VBUS_DRAW_SUSPEND is not > used > > anywhere else in your patch. The meaning of this change is "use a > > symbolic

[PATCH v2] usb/gadget: make composite gadget meet usb compliance for vbus draw

2015-07-27 Thread Du, Changbin
>From 08df419517694c4dd9ff328f5644b46a99c2999e Mon Sep 17 00:00:00 2001 From: "Du, Changbin" Date: Thu, 23 Jul 2015 20:08:04 +0800 Subject: [PATCH v2] usb/gadget: make composite gadget meet usb compliance for vbus draw USB-IF compliance requirement limits the vbus current accordi

RE: [PATCH v4 2/2] usb: dwc3: add debugfs node to dump FIFO/Queue available space

2016-04-13 Thread Du, Changbin
Hello, Sergei, > > From: "Du, Changbin" > > > > For DWC3 USB controller, the Global Debug Queue/FIFO Space Available > > Register(GDBGFIFOSPACE) can be used to dump FIFO/Queue available > space. > > Space needed before (. Okay. > > >

RE: [PATCH v4 2/2] usb: dwc3: add debugfs node to dump FIFO/Queue available space

2016-04-14 Thread Du, Changbin
If you can also add these info to each EP folder, that is awesome! :) Best Regards, Du, Changbin > -Original Message- > From: Felipe Balbi [mailto:ba...@kernel.org] > Sent: Thursday, April 14, 2016 4:03 PM > To: Du, Changbin > Cc: gre...@linuxfoundation.org; linu

RE: [PATCH v4 2/2] usb: dwc3: add debugfs node to dump FIFO/Queue available space

2016-04-14 Thread Du, Changbin
is is important in some case. We usually encounter some transfer issues but very hard to reproduce it. But we cannot enable trace all the time since performance concern. Then I thought it was so great if I can have a look for the trb status. :) Best Regards, Du, Changbin

RE: [PATCH v4 2/2] usb: dwc3: add debugfs node to dump FIFO/Queue available space

2016-04-14 Thread Du, Changbin
> Hi, > > "Du, Changbin" writes: > >> > At last, comparing with the FIFO/Queue info, I think software transfer > >> > Requests list, TRBs info, EVENTs history are much more useful for > >> debugging > >> > the driver. If

RE: [PATCH 1/2] usb: configfs: allow UDC binding rule configured as binding to *any* UDC

2016-05-05 Thread Du, Changbin
> > In a word, this patch is just an improvement, not to fix any issues or > > add new function. > > So it doesn't add any new functionality and breaks existing user space > tools. > Ok, regarding there is a better tool, this change doesn't make much sense. So just abandon it. > Cheers, > -- > Krzysztof Opasiak > Samsung R&D Institute Poland > Samsung Electronics Best Regards, Du, Changbin

RE: [PATCH] debugobjects: insulate non-fixup logic related to static obj from fixup callbacks

2016-05-08 Thread Du, Changbin
> From: Thomas Gleixner [mailto:t...@linutronix.de] > Can you please fix your mail client. Every mail you send has: > > Cc: ..... > "Du, Changbin" , > Du > > And that stray 'Du' is just broken. > Yes, I should add "" around my n

RE: [PATCH] debugobjects: insulate non-fixup logic related to static obj from fixup callbacks

2016-05-08 Thread Du, Changbin
> From: Thomas Gleixner [mailto:t...@linutronix.de] > On Sun, 8 May 2016, Du, Changbin wrote: > > > From: Thomas Gleixner [mailto:t...@linutronix.de] > > > > raw_spin_unlock_irqrestore(&db->lock, flags); > > > > /*

RE: [PATCH] usb: hub: fix panic caused by NULL bos pointer during reset device

2016-05-03 Thread Du, Changbin
t was junked by my email client. Just checked patch 464ad8c43a9e, it fix the same issue. So my patch no longer need now. Thanks for the patch. Best Regards, Du, Changbin

RE: [PATCH 1/2] usb: configfs: allow UDC binding rule configured as binding to *any* UDC

2016-05-04 Thread Du, Changbin
lem. But just avoid pseudo 'busy'. If gadget is not bind, it is free to reconfigure it. So seem no need block re-configuration. In a word, this patch is just an improvement, not to fix any issues or add new function. > Cheers, > -- > Krzysztof Opasiak > Samsung R&D Institute Poland > Samsung Electronics Thanks, Du, Changbin

RE: [PATCH] usb: gadget: f_fs: report error if excess data received

2016-05-11 Thread Du, Changbin
> Hi, > > changbin...@intel.com writes: > > From: "Du, Changbin" > > > > Since the buffer size for req is rounded up to maxpacketsize, > > then we may end up with more data then user space has space > > for. > > only for OUT direction with

RE: [PATCH] usb: gadget: f_fs: report error if excess data received

2016-05-11 Thread Du, Changbin
> On Wed, May 11 2016, Felipe Balbi wrote: > > Also, returning -EOVERFLOW is not exactly correct here, because you'd > > violate POSIX specification of read(), right ? > > Maybe we could piggyback on: > >EINVAL fd was created via a call to timerfd_create(2) and the > wrong s

RE: [PATCH] usb: gadget: f_fs: report error if excess data received

2016-05-12 Thread Du, Changbin
ace > read() more than 5 ? > > -- > Balbi Well, first, there must be a protocol upon usb between host side and device side. Second device side didn't know how many bytes to receive, it need host side tell it. But host could be buggy, or the application is killed and restart. These all can lead host send more than device wanted bytes. For sure it wrong at host side, but device side don't know. Best Regards, Du, Changbin

RE: [PATCH] usb: gadget: f_fs: report error if excess data received

2016-05-12 Thread Du, Changbin
his means we have a bug at device side. In fact, by > allowing these extra bytes to reach userspace, we could be creating a > possible attack vector. > > Your explanation is unsatisfactory, so I won't apply your patch, sorry. > > -- > balbi It is fine. Then need userspace take care of all the data it received. Because Kernel may drop some data for it. Kernel ffs driver is unauthentic sometimes. Best Regards, Du, Changbin

  1   2   3   >