blob: 5a58a0d11449522c705a446a79f1f0b99fd06c1c [file] [log] [blame]
Chris Metcalf867e3592010-05-28 23:09:12 -04001/*
2 * Copyright 2010 Tilera Corporation. All Rights Reserved.
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation, version 2.
7 *
8 * This program is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
11 * NON INFRINGEMENT. See the GNU General Public License for
12 * more details.
13 */
14
15#ifndef _ASM_TILE_UNALIGNED_H
16#define _ASM_TILE_UNALIGNED_H
17
Chris Metcalfba02f0e2013-08-07 11:55:35 -040018/*
19 * We could implement faster get_unaligned_[be/le]64 using the ldna
20 * instruction on tilegx; however, we need to either copy all of the
21 * other generic functions to here (which is pretty ugly) or else
22 * modify both the generic code and other arch code to allow arch
23 * specific unaligned data access functions. Given these functions
24 * are not often called, we'll stick with the generic version.
25 */
26#include <asm-generic/unaligned.h>
Chris Metcalf867e3592010-05-28 23:09:12 -040027
David Howellsbd119c62012-03-28 18:30:03 +010028/*
29 * Is the kernel doing fixups of unaligned accesses? If <0, no kernel
30 * intervention occurs and SIGBUS is delivered with no data address
31 * info. If 0, the kernel single-steps the instruction to discover
32 * the data address to provide with the SIGBUS. If 1, the kernel does
33 * a fixup.
34 */
35extern int unaligned_fixup;
36
37/* Is the kernel printing on each unaligned fixup? */
38extern int unaligned_printk;
39
40/* Number of unaligned fixups performed */
41extern unsigned int unaligned_fixup_count;
42
Chris Metcalf867e3592010-05-28 23:09:12 -040043#endif /* _ASM_TILE_UNALIGNED_H */