Skip to content

Commit

Permalink
Merge branch 'stable' of git://git.kernel.org/pub/scm/linux/kernel/gi…
Browse files Browse the repository at this point in the history
…t/cmetcalf/linux-tile

Pull arch/tile fix from Chris Metcalf:
 "This is a single change to fix backtracing in big-endian mode."

* 'stable' of git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile:
  arch/tile: big-endian: properly bswap instruction bundles when backtracing
  • Loading branch information
Linus Torvalds committed Jul 11, 2012
2 parents 5f8ebd3 + 9e0304e commit 605cd83
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions arch/tile/kernel/backtrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

#include <linux/kernel.h>
#include <linux/string.h>
#include <asm/byteorder.h>
#include <asm/backtrace.h>
#include <asm/tile-desc.h>
#include <arch/abi.h>
Expand Down Expand Up @@ -336,8 +337,12 @@ static void find_caller_pc_and_caller_sp(CallerLocation *location,
bytes_to_prefetch / sizeof(tile_bundle_bits);
}

/* Decode the next bundle. */
bundle.bits = prefetched_bundles[next_bundle++];
/*
* Decode the next bundle.
* TILE always stores instruction bundles in little-endian
* mode, even when the chip is running in big-endian mode.
*/
bundle.bits = le64_to_cpu(prefetched_bundles[next_bundle++]);
bundle.num_insns =
parse_insn_tile(bundle.bits, pc, bundle.insns);
num_info_ops = bt_get_info_ops(&bundle, info_operands);
Expand Down

0 comments on commit 605cd83

Please sign in to comment.