On Thu, 18 Jun 2020, Kees Cook wrote:
> On Wed, Jun 17, 2020 at 08:54:03PM +0200, Julia Lawall wrote:
> >
> >
> > On Wed, 17 Jun 2020, Kees Cook wrote:
> >
> > > On Mon, Jun 15, 2020 at 01:20:45PM +0300, Denis Efremov wrote:
> > > > +@as@
> > > > +expression E1, E2;
> > > > +@@
> > > > +
> > >
On Thu, Jun 18, 2020 at 10:37:07AM +0200, Vlastimil Babka wrote:
> On 6/10/20 6:31 PM, Vlastimil Babka wrote:
> > There are few places that call kmem_cache_debug(s) (which tests if any of
> > debug
> > flags are enabled for a cache) immediatelly followed by a test for a
> > specific
> > flag. The
No functional change, avoid non-inclusive naming schemes.
Signed-off-by: Alex Williamson
---
drivers/vfio/vfio.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/vfio/vfio.c b/drivers/vfio/vfio.c
index 580099afeaff..833da937b7fc 100644
--- a/drivers/vfio
On Thu, Jun 18, 2020 at 12:10:38PM +0200, Vlastimil Babka wrote:
>
> On 6/17/20 7:49 PM, Kees Cook wrote:
> > On Wed, Jun 10, 2020 at 06:31:35PM +0200, Vlastimil Babka wrote:
> >> The function cache_from_obj() was added by commit b9ce5ef49f00 ("sl[au]b:
> >> always get the cache from its page in k
On Mon, Jun 15, 2020 at 11:47 PM David Gow wrote:
>
> When separating out different phases of running tests[1]
> (build/exec/parse/etc), the format of the KunitResult tuple changed
> (adding an elapsed_time variable). This is not populated during a build
> failure, causing kunit.py to crash.
>
> T
From: Maciej Żenczykowski
This is a 5.8-rc1 regression.
Cc: Alexei Starovoitov
Cc: Daniel Borkmann
Fixes: 2c78ee898d8f ("bpf: Implement CAP_BPF")
Signed-off-by: Maciej Żenczykowski
---
kernel/bpf/syscall.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/bpf/syscall
On Thu, Jun 18, 2020 at 05:29:00PM +, Chaitanya Kulkarni wrote:
> I'm not against the code cleanup and it always welcome.
> Please also have a look at other comment.
>
> >> What is the issue with existing code that we need this patch for ?
> >>
> >
> > Hello Chaitanya,
> >
> > This is just
On 6/18/20 12:50 PM, Eugeniy Paltsev wrote:
> Hi Vineet,
>
> could you also peek this patch to for-curr as we don't have any disagreement
> about it?
>
> I'll respin the rest of the patches later. Thanks.
> ---
> Eugeniy Paltsev
Added !
-Vineet
Hi,
my test box won't boot 5.8-rc1 all the way but stops at
...
fb0: switching to nouveaufb from EFI VGA
<-- EOF
I've bisected it to the commit in $Subject, see below. Unfortunately, it
doesn't revert cleanly so I can't really do the final test of reverting
it ontop of 5.8-rc1 to confirm that th
Cyril Hrubis writes:
> What is does is to write:
>
> (void*)1 to u_debugreg[0]
> (void*)1 to u_debugreg[7]
> do_debug addr to u_debugreg[0]
>
> Looking at the kernel code the write to register 7 enables the breakpoints and
> what we attempt here is to change an invalid address to
Workarounds for gcc issues with initializers and anon unions was first
introduced in commit e44ac588cd61 ("drivers/block/nvme-core.c: fix build
with gcc-4.4.4").
The gcc bug in question has been fixed since gcc 4.6.0:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=10676
The minimum gcc version for
Make the nvme code more uniform by initializing struct members at
declaration time. This change is done both in drivers/nvme/host/ and
drivers/nvme/target/.
This is how the design pattern was in nvme, before workarounds for a gcc
bug were introduced in commit e44ac588cd61 ("drivers/block/nvme-core
Workarounds for gcc issues with initializers and anon unions was first
introduced in commit e44ac588cd61 ("drivers/block/nvme-core.c: fix build
with gcc-4.4.4").
The gcc bug in question has been fixed since gcc 4.6.0:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=10676
The minimum gcc version for
On Thu, Jun 18, 2020 at 10:35:27AM -0700, Matthew Wilcox wrote:
> On Thu, Jun 18, 2020 at 07:30:49PM +0200, Uladzislau Rezki wrote:
> > > I'd suggest:
> > >
> > > rcu_lock_acquire(&rcu_callback_map);
> > > trace_rcu_invoke_kfree_bulk_callback(rcu_state.name,
> >
On 18/06/2020 21.21, Kanchan Joshi wrote:
On Thu, Jun 18, 2020 at 10:04:32AM +0200, Matias Bjørling wrote:
On 17/06/2020 19.23, Kanchan Joshi wrote:
This patchset enables issuing zone-append using aio and io-uring
direct-io interface.
For aio, this introduces opcode IOCB_CMD_ZONE_APPEND. Appl
On Wed, Jun 17, 2020 at 09:18:34AM +0200, Geert Uytterhoeven wrote:
> Hi Thierry,
>
> On Mon, Jun 15, 2020 at 4:17 PM Thierry Reding
> wrote:
> > The PWM core will soon change the duty cycle and period of PWMs to 64
> > bits to allow for a broader range of values. Use a 64-bit format
> > specifi
On Thu, Jun 18, 2020 at 10:56:14AM +0200, Christian Brauner wrote:
> On Mon, Jun 15, 2020 at 08:25:15PM -0700, Kees Cook wrote:
> > In preparation for users of the "install a received file" logic outside
> > of net/ (pidfd and seccomp), relocate and rename __scm_install_fd() from
> > net/core/scm.c
the below-mentioned commit moved headers to inlucde/linux/soc/mmp. MAINTAINERS
was updated, but include/ was omitted.
Fixes: 32adcaa010 ("ARM: mmp: move cputype.h to include/linux/soc/")
Signed-off-by: Ralf Ramsauer
---
MAINTAINERS | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --gi
On Thu, Jun 18, 2020 at 12:10:38PM +0200, Vlastimil Babka wrote:
>
> On 6/17/20 7:49 PM, Kees Cook wrote:
> > On Wed, Jun 10, 2020 at 06:31:35PM +0200, Vlastimil Babka wrote:
> >> The function cache_from_obj() was added by commit b9ce5ef49f00 ("sl[au]b:
> >> always get the cache from its page in k
On 6/18/2020 11:33 AM, Rob Herring wrote:
> On Wed, Jun 17, 2020 at 12:02 PM Wesley Cheng wrote:
>
> You are duplicating everything in usb-connector.yaml. You should have
> a $ref to it.
>
Hi Rob,
Sure, I will add a reference to that doc.
>
> This is wrong. The connector binding says port
Hi,
On Thu, Jun 18, 2020 at 11:05 AM Stephen Boyd wrote:
>
> Quoting Douglas Anderson (2020-06-18 08:06:26)
> > @@ -126,20 +120,23 @@ static void handle_fifo_timeout(struct spi_master
> > *spi,
> > struct geni_se *se = &mas->se;
> >
> > spin_lock_irq(&mas->lock);
> > - rein
> On Jun 18, 2020, at 2:09 AM, Athira Rajeev
> wrote:
>
>
>
>> On 02-May-2020, at 5:51 AM, Song Liu wrote:
>>
>> This patch tries to enable PMU sharing. When multiple perf_events are
>> counting the same metric, they can share the hardware PMU counter. We
>> call these events as "compatib
IMA is not considering TPM registers 8-9 when calculating the boot
aggregate. When registers 8-9 are used to store measurements of the
kernel and its command line (e.g., grub2 bootloader with tpm module
enabled), IMA should include them in the boot aggregate.
Signed-off-by: Maurizio Drocco
---
s
On Thu, Jun 18, 2020 at 05:49:19AM +, Sargun Dhillon wrote:
> On Wed, Jun 17, 2020 at 03:03:23PM -0700, Kees Cook wrote:
> > [...]
> > static inline int fd_install_received_user(struct file *file, int __user
> > *ufd,
> >unsigned int o_flags)
> > {
> >
From: Maurizio
If PCRs 8 - 9 are set (i.e. not all-zeros), cal_bootaggr should include
them into the digest.
Signed-off-by: Maurizio Drocco
---
src/evmctl.c | 16 +++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/src/evmctl.c b/src/evmctl.c
index 1d065ce..554571e 1
> On Jun 18, 2020, at 11:33 AM, Peter Zijlstra wrote:
>
> On Thu, Jun 18, 2020 at 05:25:24PM +, Song Liu wrote:
>
[...]
>> 0xfe4d1380 __start_orc_unwind
>> 0xfe4d1388 unwind_next_frame.cold.7
>> 0xfe4d13c8 perf_callchain_kernel
>> 0xfe4d1418 entry_SYSCALL
Hi Boris,
There was a fixup to that patch that you'll also have to revert first
-- 7dbbdd37f2ae7dd4175ba3f86f4335c463b18403. I guess there's some
subtle difference between the old open-coded logic and the helper,
they were supposed to be identical.
Cheers,
-ilia
On Thu, Jun 18, 2020 at 4:09 P
On Tue, Jun 16, 2020 at 3:36 PM 'Nathan Huckleberry' via Clang Built
Linux wrote:
>
> Since clang does not push pc and sp in function prologues, the current
> implementation of unwind_frame does not work. By using the previous
> frame's lr/fp instead of saved pc/sp we get valid unwinds on clang-bu
Convert the analog TV, DVI, HDMI, and VGA connector bindings to DT schema
format.
Cc: Sam Ravnborg
Cc: Laurent Pinchart
Cc: Maxime Ripard
Signed-off-by: Rob Herring
---
I put myself as maintainer, but would be happy if someone else was like
one of the Cc'ed people.
.../display/connector/ana
On Tue, Jun 16, 2020 at 9:21 PM David Gow wrote:
>
> On Tue, Jun 16, 2020 at 5:40 PM Alan Maguire wrote:
> >
> > On Tue, 16 Jun 2020, David Gow wrote:
> >
> > > CONFIG_PM_QOS_KUNIT_TESTOn Mon, Jun 15, 2020 at 1:48 AM Kees Cook
> > > wrote:
> > > >
> > > > On Sat, Jun 13, 2020 at 02:51:17PM +0800
On Thu, Jun 18, 2020 at 1:22 PM Nick Desaulniers
wrote:
>
> On Tue, Jun 16, 2020 at 3:36 PM 'Nathan Huckleberry' via Clang Built
> Linux wrote:
> >
> > Since clang does not push pc and sp in function prologues, the current
> > implementation of unwind_frame does not work. By using the previous
>
On Wed, Jun 17, 2020 at 8:57 PM Vitor Massaru Iha wrote:
>
> Commit 8b59cd81dc5 ("kbuild: ensure full rebuild when the compiler
> is updated") added the environment variable CC_VERSION_TEXT,
> parse_from_string() doesn't expect a string and this causes the
> failure below:
>
> [iha@bbking linux]$
rcu_segcblist_accelerate() returns true if a GP is to be
started/requested and false if not. During tracing, I found that it is
asking that GPs be requested
The exact flow seems to be something like:
1. Callbacks are queued on CPU A - into the NEXT list.
2. softirq runs on CPU A, accelerate all CB
Add 2 things to get visiblity around number of grace periods.
1. Add number of GPs to End-state print.
2. Just like End-state, add GP state to Start-state.
This helps determine how many GPs elapsed during a run of rcutorture and
what the initial state was.
Signed-off-by: Joel Fernandes (Google)
Track how the segcb list changes before/after acceleration, during
queuing and during dequeuing.
This has proved useful to discover an optimization to avoid unwanted GP
requests when there are no callbacks accelerated.
Signed-off-by: Joel Fernandes (Google)
---
include/trace/events/rcu.h | 25 +
During acceleration of CB, the rsp's gp_seq is rcu_seq_snap'd. This is
the value used for acceleration - it is the value of gp_seq at which it
is safe the execute all callbacks in the callback list.
The rdp's gp_seq is not very useful for this scenario. Make
rcu_grace_period report the rsp's gp_se
This is useful to check for any improvements or degradation related to
number of GP kthread wakeups during testing.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/Kconfig.debug | 1 +
kernel/rcu/rcu.h | 2 ++
kernel/rcu/rcutorture.c | 23 ++-
kernel/rcu/tree
The gp_seq value can come from either of rdp, rsp or rnp.
Only the rsp is the global source of truth (most accurate GP info). The
rnp can be off by ~1 and the rdp can be off by way more. Add some more
context to traces to clarify where it comes from.
Signed-off-by: Joel Fernandes (Google)
---
i
GP numbers start from -300 and gp_seq numbers start of -1200 (for a
shift of 2). These negative numbers are printed as unsigned long which
not only takes up more text space, but is rather confusing to the reader
as they have to constantly expend energy to truncate the number. Just
print the negativ
On Thu, Jun 18, 2020 at 5:39 AM Vitor Massaru Iha wrote:
>
> Commit 8b59cd81dc5 ("kbuild: ensure full rebuild when the compiler
> is updated") added the environment variable CC_VERSION_TEXT,
> parse_from_string() doesn't expect a string in value field and this
> causes the failure below:
>
> [iha@
On Thu, Jun 18, 2020 at 12:03:59PM -0700, Paul E. McKenney wrote:
> On Thu, Jun 18, 2020 at 08:34:48PM +0200, Uladzislau Rezki wrote:
> > > > >
> > > > > I suspect that he would like to keep the tracing.
> > > > >
> > > > > It might be worth trying the branches, given that they would be
> > > >
On Thu, 2020-06-18 at 13:29 -0700, Brendan Higgins wrote:
> On Wed, Jun 17, 2020 at 8:57 PM Vitor Massaru Iha
> wrote:
> > Commit 8b59cd81dc5 ("kbuild: ensure full rebuild when the compiler
> > is updated") added the environment variable CC_VERSION_TEXT,
> > parse_from_string() doesn't expect a st
parent cannot be NULL here since its in the else part
of the if (parent == NULL) condition. Remove the extra
check on parent pointer.
Signed-off-by: Gaurav Singh
---
net/sched/sch_api.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/sched/sch_api.c b/net/sched/sch_api.
On Wed, Jun 17, 2020 at 01:01:51PM -0700, Matthew Wilcox wrote:
> On Wed, Jun 17, 2020 at 12:53:48PM -0700, Kees Cook wrote:
> > Include SLAB and SLOB caches when performing kmem_cache pointer
>
> ... SLOB? Really? Objects from different kmem caches are mixed together
> on the same page with SLO
On Thu, Jun 18, 2020 at 10:35:57PM +0200, Uladzislau Rezki wrote:
> On Thu, Jun 18, 2020 at 12:03:59PM -0700, Paul E. McKenney wrote:
> but i do not have a strong opinion here, even though i tend to
> say that it would be odd. Having just vfree_bulk(), i think
> would be enough, as a result the cod
recordmcount has its own ELF wrapper code and could utilize
objtool's ELF code to more-portably handle architecture variations.
This series makes recordmcount a subcommand of objtool. It very
gradually converts recordmcount to become a subcommand of objtool and
then reuses parts of objtool's ELF co
Currently the reasons to build and run objtool are:
Stack validation (objtool subcmds: orc + check)
Orc data generation (objtool subcmds: orc)
Code analysis (objtool subcmds: check)
Since the reasons are varied and the stack validation step is
skipped with a warning if libe
Use objtool's ELF data structures to visit the relocation
sections in the top-level ELF file walking function, do_func().
This means we can pass pointers to the relocation header structures
into nested functions and avoid the indexing patterns for them.
These conversions don't use libelf/objtool t
Rather than open coding symbol name lookups in get_sym_and_*()
we rename the structure and use objtool's lookup function to
get the symbol name for a relocation. We also change the name
of the function to better reflect its purpose.
Signed-off-by: Matt Helsley
---
tools/objtool/elf.c |
recordmcount iterates over the sections in the order they're
listed in the ELF file and checks whether the section name
indicates it's of interest. Objtool's elf code works differently
-- it scans the elf file and builds up data structures
representing the headers, sections, etc. and then supplies
We can use the objtool GElf_Ehdr structure to access ehdr here.
This makes the function completely independent of the old
recordmcount ELF wrapper. The next step will be to promote it
to the C file.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.h | 13 ++---
1 file changed,
Move where we detect the size of relocation entries we wish to
use into the first loop over the sections. This will allow us
to allocate the mcount location and relocation sections before
the next loop that collects them.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 8 +---
Since we're no longer writing to the ELF file mapping and we're
not appending to it we don't need to keep more information from the
stat structure. At the same time we can give the smaller global
variable a better name.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 9 ++---
This function is no longer dependent upon the old recordmcount
ELF wrapper code -- it doesn't use the wrapper's Elf_* types nor
does it call wrapped functions. Move it into the C file.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 42
tools/objto
The nop_mcount() function overwrites mcount calls that should be
ignored with no-ops. This operation varies by architecture and
wordsize so we retain the function pointers used to implement
the fundamental operation while nop_mcount() itself is responsible
for walking the relocations, determining i
Replace MIPS is_fake_mcount code using Elf_Addr with
unsigned long for the offsets. This is consistent with the way
that objtool more generally treats offsets and removes the
last use of the Elf_Addr wrapper.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.h | 9 +++--
1 file chan
Rather than modify the pseudo-mapping of the ELF file directly,
which is the recordmcount way of operating, use the objtool
section list and generic ELF functions to modify the ELF file.
This eliminates a bunch of code -- the ulseek() and uwrite()
functions -- because it's used to patch the ELF da
The name of the object file being processed is unused in
the wrapper's leaf functions so we no longer need to pass
it as a parameter.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 4 ++--
tools/objtool/recordmcount.h | 19 ---
2 files changed, 10 insertions(+),
The has_rel_mcount() and tot_relsize() helpers are no longer
dependent on the ELF wrapper so we can move them.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 26 ++
tools/objtool/recordmcount.h | 33 -
2 files changed, 26 in
Instead of hard-coding what amounts to a memcmp() use memcmp to
determine if the instruction we wish to replace matches what we
expect. This makes the x86 code more like that of, for instance,
ARM.
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 19 ++-
1 file changed, 6
One flag is only for relocation sections and the other only
for text (not relocation) sections so we can share the same
flag and test the section type when we need to.
Signed-off-by: Matt Helsley
---
tools/objtool/elf.c| 5 ++---
tools/objtool/elf.h| 2 +-
tools/objtool/mcount.c | 9
Now that this function no longer uses any of the old recordmcount
wrapper code we can move it out of the wrapper too.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 47 +
tools/objtool/recordmcount.h | 50
2 fil
To reduce the need for an initial pass through the sections
we need to keep lists of mcount call locations and suitable
relocations. A subsequent patch will eliminate the need for
the first pass entirely.
Introduce a new list for the locations and reuse objtool's
relocation lists respectively.
Si
Now that we've converted recordmcount to a subcommand of objtool
rename the .c file in order to follow the convention of the other
objtool subcmds.
Signed-off-by: Matt Helsley
---
tools/objtool/Build| 2 +-
tools/objtool/{recordmcount.c => mcount.c} | 0
2 files changed,
The ELF header is the very first structure in an ELF file.
Rather than cast it from the file mapping we use the ELF
header extracted via objtool's ELF code.
This is the last usage of the open-coded mapping of the ELF
file which we will remove in a later step.
Signed-off-by: Matt Helsley
---
too
objtool's elf_write_insn() does extra checking when writing to
an instruction so use that rather than a plain memcpy().
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 10 --
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/tools/objtool/mcount.c b/tools/objtool/mco
Now that we add an initially-empty relocation section and share
the libelf data buffer from the beginning, we can safely use
objtools elf_create_reloc_section() function to simplify the
code further -- use the anticipated base section name, avoid
the need to set sh_info, etc. The only remaining dif
Determine the size of the mcount relocations in objtool's
ELF reading code. This reduces the number of passes we make
through the list of sections (which can become large due to
things like -ffunction-sections).
Signed-off-by: Matt Helsley
---
tools/objtool/elf.c| 2 ++
tools/objtool/elf.h
We no longer need to double-include the recordmcount.h wrapper
All of the types and functions that rely on them have been converted
to using objtool's ELF code. This moves the remaining function to
recordmcount.c and changes the function name to something slightly
more descriptive while dropping th
Let the compiler know we won't be modifying the instruction
patterns we use to determine how to turn ARM instruction(s)
into nops, and the nop instruction(s) we'll put in their
place.
Also, while we're at it, convert to unsigned char because the
next patch will need that as well.
Signed-off-by: M
Suggested-by: Peter Zijlstra
Signed-off-by: Matt Helsley
---
tools/objtool/check.c | 3 +--
tools/objtool/elf.c | 7 +++
tools/objtool/elf.h | 1 +
3 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/tools/objtool/check.c b/tools/objtool/check.c
index 78375908acda..d08714b878c
Move the check for relocations sections that apply to
mcountable text sections into objtool's ELF code.
Signed-off-by: Matt Helsley
---
tools/objtool/elf.c| 13 +
tools/objtool/elf.h| 2 +-
tools/objtool/mcount.c | 36
3 files changed, 30
Remove the last uses of the Elf_Rela wrapper by passing the
size of the relocations we're dealing with as a parameter.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 4 ++--
tools/objtool/recordmcount.h | 7 ++-
2 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/t
Move the test for mcount symbols into the ELF code itself
and set a class on indicator on the symbol. This simplifies
mcount a little and tests the symbols names near where they're
first touched so should be cache-hot and may also help us
reduce the number of passes through the ELF contents needed
Remove gpfx -- the recognized prefix for the mcount symbol
-- and just recognize any of the prefixes. This allows us
to further substitute the various strings directly into the
code rather than using variables.
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 19 ---
1 fi
The comments at the top no longer reflect how we process the ELF
contents. More helpful comments are inline with the code so we
don't need the top comments either.
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 13 -
1 file changed, 13 deletions(-)
diff --git a/tools/objto
In preparation for removing this first pass by mcount move
the test for whether a section is mcountable into objtool's
ELF read code, much like we did with the symbol name. A
subsequent patch will eliminate the tot_relsize() function
and thereby reduce the number of passes through the ELF
data.
Si
Now that it's been stripped of using the old recordmcount ELF
wrapper get_mcountsym() is ready to be promoted out of the
double-included wrapper header.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 16
tools/objtool/recordmcount.h | 19 ---
2 fi
Rather than passing in the string table contents as a parameter,
pass in the section index of the string table and rely on libelf
string table accessor functions to look up section names.
Note that modifying the string table with libelf will come later
so append_func() is unchanged.
Signed-off-by
Since the relocation section's sh_info points back to the text
section it applies to and we already have that we can just pass
it in and greatly simplify find_section_sym_index().
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 39 +++
1 file changed,
Before we can move this function out of the wrapper and into
wordsize-independent code we need to return the relocation
symbol information in a size-independent fashion. Previously
we compared the raw info bits but that requires passing around
an unsigned long. Instead we just use a pointer to the
Now that they're no longer used we can remove these endian
wrappers.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 63
1 file changed, 63 deletions(-)
diff --git a/tools/objtool/recordmcount.c b/tools/objtool/recordmcount.c
index 7f4d18e83e2
Rather than use the size of the relocations check the section
header type directly to see if the mcount relocations should
be rel or rela relocations.
Signed-off-by: Matt Helsley
---
tools/objtool/elf.c| 4 ++--
tools/objtool/elf.h| 2 +-
tools/objtool/mcount.c | 15 +--
3
Setting altmcount only when processing ARM ELF files is
not necessary -- we can make the code easier to read
by always checking for the string.
Signed-off-by: Matt Helsley
---
tools/objtool/mcount.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/tools/objtool/mcount.c b/t
Hi,
On Thu, Jun 18, 2020 at 04:19:02PM -0400, Ilia Mirkin wrote:
> Hi Boris,
>
> There was a fixup to that patch that you'll also have to revert first
> -- 7dbbdd37f2ae7dd4175ba3f86f4335c463b18403. I guess there's some
> subtle difference between the old open-coded logic and the helper,
> they we
Rather than building the exact ELF section data we need and
avoiding libelf's conversion step, use more GElf types
and then libelf's elfxx_xlatetof() functions to convert
the mcount locations (GElf_Addr) and associated relocations.
This converts sift_rel_mcount() so that it doesn't use the
recordm
Hi David,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v5.8-rc1 next-20200618]
[cannot apply to kvmarm/next arm64/for-next/core arm-perf/for-next/perf]
[If your patch is applied to the wrong git tree, kindly drop us
The mcount_adjust variable defines how many bytes to move back
from the relocation address in order to be able to get to the
start of the function call instruction(s) needed to turn it
into a no-op. The values are very small and signed so we don't
need to worry about changing the size of the variab
Use the ehdr parameter to append_func() to write the ELF file's
header but use the objtool ELF header data as the basis for
making changes. The makes it clearer when we can switch from
using the old recordmcount wrapper to write the ELF file
because ehdr will only be passed on to uwrite() calls and
The ELF data is now accessed completely through objtool's
ELF code. We can remove the mapping of the original ELF
file and propagate elf_open_read(), elf_close(), and malloc()
up in place of mmap_file(), mmap_cleanup(), and umalloc()
respectively. This also eliminates the last use of the
umalloc()
Rather than allocating the ELF sections after collecting the
mcount locations and building the relocation entries, create
the empty sections beforehand. This has the benefit of
removing the memcpy() and just using the resulting libelf
buffers directly.
Signed-off-by: Matt Helsley
---
tools/objto
Promote the now-bit-independent is_fake_mcount() out of the old
recordmcount ELF wrapper.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 48 +++---
tools/objtool/recordmcount.h | 50
2 files changed, 45 insertions(+
Use a new loc_size parameter to append_func() rather than
use the wrapper's _size macro directly.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.h | 11 ++-
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/tools/objtool/recordmcount.h b/tools/objtool/recordmcount
Rather than a standalone executable merge recordmcount as a sub command
of objtool. This is a small step towards cleaning up recordmcount and
eventually sharing ELF code with objtool.
For the initial step all that's required is a bit of Makefile changes
and invoking the former main() function fro
Move recordmcount into the objtool directory. We keep this step separate
so changes which turn recordmcount into a subcommand of objtool don't
get obscured.
Signed-off-by: Matt Helsley
---
Documentation/trace/ftrace-design.rst | 4 ++--
Documentation/trace/ftrace.rst | 2 +-
M
Since it's no longer needed in the rest of do_func() we can move
it to where it's needed rather than pass it as a parameter.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tools/objtool/recordmcount.h b/tools
Rather than using indices into raw ELF32/64 tables mapped for the
wrapper, use the objtool functions to find the suitable symbol
in the given text section. This also removes all callers to
find_symtab() and get_symindex() so we can remove them as well.
Also take advantage of this commit to rename
Use struct elf to grab the file descriptor. We will later
move these calls into other functions as we expand the
lifetime of the struct elf so that it can be passed to
objtool elf.[ch] functions.
This creates the libelf/objtool data structures and gives
us two separate ways to walk the ELF file --
On Thu, Jun 18, 2020 at 12:27:07PM +0300, Mike Rapoport wrote:
> Hi Roman,
>
> On Mon, Jun 08, 2020 at 04:06:35PM -0700, Roman Gushchin wrote:
> > This is v6 of the slab cgroup controller rework.
> >
> > The patchset moves the accounting from the page level to the object
> > level. It allows to s
Rather than walk the section tables using the old recordmcount mapping
of the ELF file, walk the section list provided by objtool's ELF code.
This removes the last use of of the Elf_r_sym wrapper so we remove
that too.
Signed-off-by: Matt Helsley
---
tools/objtool/recordmcount.c | 10 +---
tool
701 - 800 of 1302 matches
Mail list logo