2010-05-28 23:09:12 -04:00
|
|
|
|
2011-02-28 15:58:39 -05:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
|
|
|
|
|
2014-01-28 10:03:50 +08:00
|
|
|
|
|
|
|
|
|
2012-06-15 15:23:06 -04:00
|
|
|
|
|
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
|
|
|
|
|
2012-10-08 16:28:16 -07:00
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
2012-10-08 16:28:11 -07:00
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
|
|
|
|
|
2011-03-25 14:21:17 +00:00
|
|
|
|
2012-10-08 16:28:13 -07:00
|
|
|
|
2013-03-07 15:48:16 +11:00
|
|
|
|
arch/tile: more /proc and /sys file support
This change introduces a few of the less controversial /proc and
/proc/sys interfaces for tile, along with sysfs attributes for
various things that were originally proposed as /proc/tile files.
It also adjusts the "hardwall" proc API.
Arnd Bergmann reviewed the initial arch/tile submission, which
included a complete set of all the /proc/tile and /proc/sys/tile
knobs that we had added in a somewhat ad hoc way during initial
development, and provided feedback on where most of them should go.
One knob turned out to be similar enough to the existing
/proc/sys/debug/exception-trace that it was re-implemented to use
that model instead.
Another knob was /proc/tile/grid, which reported the "grid" dimensions
of a tile chip (e.g. 8x8 processors = 64-core chip). Arnd suggested
looking at sysfs for that, so this change moves that information
to a pair of sysfs attributes (chip_width and chip_height) in the
/sys/devices/system/cpu directory. We also put the "chip_serial"
and "chip_revision" information from our old /proc/tile/board file
as attributes in /sys/devices/system/cpu.
Other information collected via hypervisor APIs is now placed in
/sys/hypervisor. We create a /sys/hypervisor/type file (holding the
constant string "tilera") to be parallel with the Xen use of
/sys/hypervisor/type holding "xen". We create three top-level files,
"version" (the hypervisor's own version), "config_version" (the
version of the configuration file), and "hvconfig" (the contents of
the configuration file). The remaining information from our old
/proc/tile/board and /proc/tile/switch files becomes an attribute
group appearing under /sys/hypervisor/board/.
Finally, after some feedback from Arnd Bergmann for the previous
version of this patch, the /proc/tile/hardwall file is split up into
two conceptual parts. First, a directory /proc/tile/hardwall/ which
contains one file per active hardwall, each file named after the
hardwall's ID and holding a cpulist that says which cpus are enclosed by
the hardwall. Second, a /proc/PID file "hardwall" that is either
empty (for non-hardwall-using processes) or contains the hardwall ID.
Finally, this change pushes the /proc/sys/tile/unaligned_fixup/
directory, with knobs controlling the kernel code for handling the
fixup of unaligned exceptions.
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
2011-05-26 12:40:09 -04:00
|
|
|
|
2013-04-30 15:28:42 -07:00
|
|
|
|
2012-03-27 13:47:57 -04:00
|
|
|
|
2012-05-18 16:45:54 +00:00
|
|
|
|
2012-09-28 14:31:03 +09:30
|
|
|
|
2012-12-22 00:21:12 -05:00
|
|
|
|
2013-01-21 19:54:57 -05:00
|
|
|
|
tile: improve stack backtrace
This commit fixes a number of issues with the tile backtrace code.
- Don't try to identify userspace shared object or executable paths
if we are doing a backtrace from an interrupt; it's not legal,
and also unlikely to be interesting. Likewise, don't try to do
it for other address spaces, since d_path() assumes it is being
called in "current" context.
- Move "in_backtrace" from thread_struct to thread_info.
This way we can access it even if our stack thread_info has been
clobbered, which makes backtracing more robust.
- Avoid using "current" directly when testing for is_sigreturn().
Since "current" may be corrupt, we're better off using kbt->task
explicitly to look up the vdso_base for the current task.
Conveniently, this simplifies the internal APIs (we only need
one is_sigreturn() function now).
- Avoid bogus "Odd fault" warning when pc/sp/ex1 are all zero,
as is true for kernel threads above the last frame.
- Hook into Tejun Heo's dump_stack() framework in lib/dump_stack.c.
- Write last entry in save_stack_trace() as ULONG_MAX, not zero,
since ftrace (at least) relies on finding that marker.
- Implement save_stack_trace_regs() and save_strack_trace_user(),
and set CONFIG_USER_STACKTRACE_SUPPORT.
Signed-off-by: Chris Metcalf <cmetcalf@ezchip.com>
2015-05-08 10:27:35 -04:00
|
|
|
|
2013-02-01 12:37:48 -05:00
|
|
|
|
2013-07-01 13:04:42 -07:00
|
|
|
|
2013-08-12 15:00:51 -04:00
|
|
|
|
2015-03-23 14:23:58 -04:00
|
|
|
|
2015-05-21 19:59:31 +02:00
|
|
|
|
2015-04-30 15:12:42 -04:00
|
|
|
|
|
|
|
|
|
2015-07-22 14:30:14 -04:00
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-02-28 15:58:39 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-01-19 20:44:43 +01:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-02-28 15:58:39 -05:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-04-01 14:04:21 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-08-07 15:33:32 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-27 15:11:07 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-03-30 22:57:33 -03:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-27 15:32:58 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-03-27 13:53:30 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-15 15:23:06 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-01-17 22:44:22 -08:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
2013-08-06 14:11:21 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
2015-06-03 10:37:56 -04:00
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
2015-06-03 10:37:56 -04:00
|
|
|
|
2014-05-07 15:44:16 +00:00
|
|
|
|
|
|
|
|
|
2013-08-09 13:26:09 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-08-09 15:08:57 -04:00
|
|
|
|
|
|
|
|
|
2013-08-28 19:53:17 -04:00
|
|
|
|
2014-08-01 15:26:46 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
2012-04-07 15:58:24 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
2012-04-07 15:58:24 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-03-27 13:53:30 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
2015-04-14 15:46:08 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
2013-01-31 21:21:36 -05:00
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-03-29 13:58:43 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-12-22 12:28:51 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-03-29 13:58:43 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-09-09 15:38:55 -07:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-07-22 14:30:14 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-08-15 16:23:24 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-03-27 13:56:04 -04:00
|
|
|
|
2010-09-13 08:50:09 -04:00
|
|
|
|
|
|
|
|
|
2011-02-28 16:01:09 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-08-07 11:36:54 -04:00
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-09-16 13:02:57 -04:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
arch/tile: Add driver to enable access to the user dynamic network.
This network (the "UDN") connects all the cpus on the chip in a
wormhole-routed dynamic network. Subrectangles of the chip can
be allocated by a "create" ioctl on /dev/hardwall, and then to access the
UDN in that rectangle, tasks must perform an "activate" ioctl on that
same file object after affinitizing themselves to a single cpu in
the region. Sending a wormhole-routed message that tries to leave
that subrectangle causes all activated tasks to receive a SIGILL
(just as they would if they tried to access the UDN without first
activating themselves to a hardwall rectangle).
The original submission of this code to LKML had the driver
instantiated under /proc/tile/hardwall. Now we just use a character
device for this, conventionally /dev/hardwall. Some futures planning
for the TILE-Gx chip suggests that we may want to have other types of
devices that share the general model of "bind a task to a cpu, then
'activate' a file descriptor on a pseudo-device that gives access to
some hardware resource". As such, we are using a device rather
than, for example, a syscall, to set up and activate this code.
As part of this change, the compat_ptr() declaration was fixed and used
to pass the compat_ioctl argument to the normal ioctl. So far we limit
compat code to 2GB, so the difference between zero-extend and sign-extend
(the latter being correct, eventually) had been overlooked.
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2010-06-25 17:00:56 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-14 16:23:03 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-05-02 15:29:04 -04:00
|
|
|
|
|
|
|
|
|
2010-10-14 16:23:03 -04:00
|
|
|
|
2013-05-02 15:29:04 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-14 16:23:03 -04:00
|
|
|
|
arch/tile: introduce GXIO IORPC framework for tilegx
The GXIO I/O RPC subsystem handles exporting I/O hardware resources to
Linux and to applications running under Linux.
For instance, memory which is made available for I/O DMA must be mapped
by an I/O TLB; that means that such memory must be locked down by Linux,
so that it is not swapped or otherwise reused, as long as those I/O
TLB entries are active. Similarly, configuring direct hardware access
introduces new validation requirements. If a user application registers
memory, Linux must ensure that the supplied virtual addresses are valid,
and turn them into client physical addresses. Similarly, when Linux then
supplies those client physical addresses to the Tilera hypervisor, it
must in turn validate those before turning them into the real physical
addresses which are required by the hardware.
To the extent that these sorts of activities were required on previous
TILE architecture processors, they were implemented in a device-specific
fashion. This meant that every I/O device had its own Tilera hypervisor
driver, its own Linux driver, and in some cases its own user-level
library support. There was a large amount of more-or-less functionally
identical code in different places, particularly in the different Linux
drivers. For TILE-Gx, this support has been generalized into a common
framework, known as the I/O RPC framework or just IORPC.
The two "gxio" directories (one for headers, one for sources) start
with just a few files in each with this infrastructure commit, but
after adding support for the on-board I/O shims for networking, PCI,
USB, crypto, compression, I2CS, etc., there end up being about 20 files
in each directory.
More information on the IORPC framework is in the <hv/iorpc.h> header,
included in this commit.
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
2012-04-04 16:39:58 -04:00
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-11-02 12:05:10 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-11-29 20:42:56 +02:00
|
|
|
|
2012-04-07 17:10:17 -04:00
|
|
|
|
|
|
|
|
|
2010-11-02 12:05:10 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-04-07 15:39:19 -07:00
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
2013-08-02 16:45:22 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
2013-08-05 13:20:44 -04:00
|
|
|
|
|
|
|
|
|
2012-05-09 13:58:14 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-05-28 23:09:12 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-14 16:23:03 -04:00
|
|
|
|
|
|
|
|
|