| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch hoists nearly all of the non-GEDF specific code (decision
making (GEDF) vs. carrying out decisions (non-specific)) out of
sched_gsn_edf.c and into a new generic sched_global_plugin architecture.
A new struct, sched_global_plugin, provides the needed hooks for other
GEDF-style schedulers to reuse the non-scheduler-specific code.
You may conceptualize this new architecture (in OO-terms) as:
* sched_plugin is the parent of sched_global_plugin.
* sched_global_plugin is the parent of gsn_edf_plugin.
* Both sched_plugin and sched_global_plugin are "pure virtual"
This patch drastically reduces the amount of code needed to support
G-EDF, EDZL, (Adaptive) EDZL, etc.
|
|
|
|
|
|
| |
This patch changes Feather-Trace to allocate memory for the minor
devices dynamically, which addresses a long-standing FIXME. It also
provides clean module exit and error conditions for Feather-Trace.
|
|
|
|
|
|
|
|
|
|
| |
This patch implements support for Feather-Trace devices to use the sysfs
file system and, consequently, udev support.
This allows us to allocate major/minor numbers for Feather-Trace
devices dynamically, which is desirable because our old static
allocations tend to create conflicts on modern distributions and/or
when there are many cores.
|
|
|
|
|
|
|
| |
Refactor the code that determines the C-EDF cluster size.
- Use an enum with symbolic constants instead of magic int values.
- Complain and fail to switch if an unsupported cluster size is requested.
- Default to ALL as suggested by Glenn and Andrea.
|
|
|
|
|
|
|
|
|
| |
Do not use the "scheduled_on" field to address the cpus structure
within a cluster. cpus may contain less items than num_online_cpus and
we may cause an out-of-bound access. Instead, use "scheduled_on" to
directly access the per-cpu cpu_entry_t structure.
Reported-by: Jonathan Herman <hermanjl@cs.unc.edu>
|
|
|
|
|
|
|
| |
budget_remaining() reports incorrect values due to the operands being
switched, which leads to an integer underflow.
Reported-by: Chris Kenna <cjk@cs.unc.edu>
|
|
|
|
|
|
|
| |
Make sure to check for maximum index value when accessing cedf_domain_t
array in cedf_activate_plugin().
Reported-by: Jeremy Erickson <jerickso@cs.unc.edu>
|
|
|
|
|
|
|
|
|
|
|
| |
Add information to each trace message that makes it easier to locate
where it came from. It is disabled by default since this adds a lot of
clutter. Example:
81281 P1 [gsnedf_schedule@litmus/sched_gsn_edf.c:406]: (rtspin/1483:1) blocks:0 out_of_time:0 np:0 sleep:1 preempt:0 state:0 sig:0
81282 P1 [job_completion@litmus/sched_gsn_edf.c:303]: (rtspin/1483:1) job_completion().
81283 P1 [__add_release@litmus/rt_domain.c:344]: (rtspin/1483:2) add_release(), rel=41941764351
81284 P1 [gsnedf_schedule@litmus/sched_gsn_edf.c:453]: (rtspin/1483:2) scheduled_on = NO_CPU
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For some problems it can be helpful to know which job of a task
generated a log message. This patch changes TRACE_TASK to add :<jobno>
to the existing (<comm>/<pid>) tag.
The result is a trace such as the following, in which the third job of
rtspin/1511 completes and the fourth job is added to the release
queue.
137615 P0: (rtspin/1511:3) job_completion().
137616 P0: (rtspin/1511:4) add_release(), rel=262013223089
137617 P0: (rtspin/1511:4) scheduled_on = NO_CPU
The job number for non-real-time tasks is always zero.
|
|
|
|
|
|
|
|
|
|
|
| |
The CPU triggering the plugin switch should wait until all other CPUs
are in a proper state (synch_on_plugin_switch()) before performing the
actual switch.
Based on the original patch from Jeremy Erickson <jerickso@cs.unc.edu>.
This should solve (for most practical cases) the C-EDF-related
plugin-switch problem reported on the ML.
|
|
|
|
|
| |
It's not being allocated per cpu anymore. Further, provide a hint to
the user where to find the data in userspace.
|
|
|
|
|
|
|
|
|
|
|
| |
Let the user choose an appropriate buffer size (instead of scaling
with NR_CPUS). The kfifo api requires the buffer to be a power of
two, so enforce this constraint in the configuration.
This fixes a previously-existing compile-time error for values of
NR_CPU that are not a power of two.
Based on a patch by Mac Mollison <mollison@cs.unc.edu>.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Disabling the clock update seems to be causing problems even in normal
Linux, and causes major bugs under LITMUS^RT. As a workaround, just
disable this "optimization" for now.
Details: the idle load balancer causes tasks that suspsend to be
marked with set_tsk_need_resched(). When such a task resumes, it may
wrongly trigger the setting of skip_clock_update. However, a
corresponding rescheduling event may not happen immediately, such that
the currently-scheduled task is no longer charged for its execution
time.
|
|
|
|
|
|
| |
Linux now has a macro of the same name, which causes namespace
collisions. Since our version is only being used in two places that
haven't triggered in several years, let's just remove it.
|
|
|
|
|
| |
The specifier %u doesn't match sizeof() if sizeof() returns a 64bit
quantity on x86_64. Always cast it to int to avoid the warning.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since the intial rebased from .24 to .32, the TRACE() implementation
was a hybrid between our old ringbuffer implementation and the new
generic kfifo API. This was a) ugly and b) not save for TRACE()
invoctations during early boot.
This patch rips out the old parts and replaces the actual buffer with a static kfifo.
This also increases TRACE() buffer size considerably. As we avoid a
dynamic allocation, this a larger size is less problematic for debug
builds. This helps a bit with holes in the debug log if the
buffer-flushing task is starved.
|
|
|
|
| |
Call into scheduler state machine in the IPI handler.
|
|
|
|
| |
Call into scheduler state machine in the IPI handler.
|
|
|
|
|
|
|
|
|
|
|
|
| |
To date, Litmus has just hooked into the smp_send_reschedule() IPI
handler and marked tasks as having to reschedule to implement remote
preemptions. This was never particularly clean, but so far we got away
with it. However, changes in the underlying Linux, and peculartities
of the ARM code (interrupts enabled before context switch) break this
naive approach. This patch introduces new state-machine based remote
preemption support. By examining the local state before calling
set_tsk_need_resched(), we avoid confusing the underlying Linux
scheduler. Further, this patch avoids sending unncessary IPIs.
|
|
|
|
|
| |
Litmus plugins should also be activated if ticks are triggered by
hrtimer.
|
|
|
|
|
|
|
|
|
|
| |
The TRACE() functionality doesn't need all of litmus.h. Currently,
it's impossible to use TRACE() in sched.h due to a circular
dependency. This patch moves TRACE() and friends to
litmus/sched_debug.h, which can be included in sched.h.
While at it, also fix some minor include ugliness that was revealed by
this change.
|
|
|
|
|
| |
Large sched_trace buffers cause boot problems on the ARM box. Allow
the user to specify smaller buffers.
|
|
|
|
|
| |
Includes the LITMUS^RT-specifc unistd.h extension and modifies the
actual syscall table.
|
|
|
|
| |
Make the ARM built aware of the LITMUS^RT-specific options.
|
|
|
|
|
| |
Use the CCNT register to override the default get_cycles() implementation in
arch/arm/asm/timex.h. This is useful for overhead measurements and debugging.
|
|
|
|
|
|
| |
Some platforms have access to a cycle coutner (CCNT) register in the
CP15 coprocessor. This trivial change will allow such platforms to provide
specialized implementations.
|
|
|
|
|
|
|
| |
Make use of the new per-plugin proc file infrastructure to avoid
littering the global namespace. While at it, also move all the
relevant bits to sched_cedf.c. In the future, each plugin's parameters
should be handled in the respective plugin file.
|
| |
|
|
|
|
|
|
| |
Change the Litmus proc layout so that loaded plugins are visible in
/proc/litmus/plugins/loaded and add Litmus functions make_plugin_proc_dir()
and remove_plugin_proc_dir() to add per-plugin proc directories.
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
Makefile
arch/x86/include/asm/unistd_32.h
arch/x86/kernel/syscall_table_32.S
kernel/sched.c
kernel/time/tick-sched.c
Relevant API and functions changes (solved in this commit):
- (API) .enqueue_task() (enqueue_task_litmus),
dequeue_task() (dequeue_task_litmus),
[litmus/sched_litmus.c]
- (API) .select_task_rq() (select_task_rq_litmus)
[litmus/sched_litmus.c]
- (API) sysrq_dump_trace_buffer() and sysrq_handle_kill_rt_tasks()
[litmus/sched_trace.c]
- struct kfifo internal buffer name changed (buffer -> buf)
[litmus/sched_trace.c]
- add_wait_queue_exclusive_locked -> __add_wait_queue_tail_exclusive
[litmus/fmlp.c]
- syscall numbers for both x86_32 and x86_64
|
| | |
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus:
MIPS: O32 compat/N32: Fix to use compat syscall wrappers for AIO syscalls.
MAINTAINERS: Change list for ioc_serial to linux-serial.
SERIAL: ioc3_serial: Return -ENOMEM on memory allocation failure
MIPS: jz4740: Fix Kbuild Platform file.
MIPS: Repair Kbuild make clean breakage.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
[Ralf: Michel's original patch only fixed N32; I replicated the same fix
for O32.]
Signed-off-by: Michel Thebeau <michel.thebeau@windriver.com>
Cc: paul.gortmaker@windriver.com
Cc: bruce.ashfield@windriver.com
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
IOC3 is also being used on SGI MIPS systems but this particular driver is
only being used on IA64 systems so linux-mips made no sense as a list. Pat
also thinks linux-serial@vger.kernel.org is the better list.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In this code, 0 is returned on memory allocation failure, even though other
failures return -ENOMEM or other similar values.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
expression ret;
expression x,e1,e2,e3;
@@
ret = 0
... when != ret = e1
*x = \(kmalloc\|kcalloc\|kzalloc\)(...)
... when != ret = e2
if (x == NULL) { ... when != ret = e3
return ret;
}
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
To: Pat Gefre <pfg@sgi.com>
Cc: kernel-janitors@vger.kernel.org
Cc: linux-ia64@vger.kernel.org
Cc: linux-mips@linux-mips.org
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/1704/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The platform specific files should be included via the platform-y
variable.
Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Cc: Lars-Peter Clausen <lars@metafoo.de>
Patchwork: https://patchwork.linux-mips.org/patch/1719/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When running make clean, Kbuild doesn't process the .config file, so nothing
generates a platform-y variable. We can get it to descend into the platform
directories by setting $(obj-).
The dec Platform file was unconditionally setting platform-, obliterating
its previous contents and preventing some directories from being cleaned.
This is change to an append operation '+=' to allow cavium-octeon to be
cleaned.
Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Patchwork: https://patchwork.linux-mips.org/patch/1718/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If the host is slow in reading data or doesn't read data at all,
blocking write calls not only blocked the program that called write()
but the entire guest itself.
To overcome this, let's not block till the host signals it has given
back the virtio ring element we passed it. Instead, send the buffer to
the host and return to userspace. This operation then becomes similar
to how non-blocking writes work, so let's use the existing code for this
path as well.
This code change also ensures blocking write calls do get blocked if
there's not enough room in the virtio ring as well as they don't return
-EAGAIN to userspace.
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
CC: stable@kernel.org
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
|
| |\ \
| | | |
| | | |
| | | |
| | | |
| | | | |
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
[SCSI] bsg: fix incorrect device_status value
[SCSI] Fix VPD inquiry page wrapper
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
bsg incorrectly returns sg's masked_status value for device_status.
[jejb: fix up expression logic]
Reported-by: Douglas Gilbert <dgilbert@interlog.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Fix two bugs in the VPD page wrapper:
- Don't return failure if the user asked for page 0
- The end of buffer check failed to account for the page header size
and consequently didn't work
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
* 'kvm-updates/2.6.36' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
KVM: Fix fs/gs reload oops with invalid ldt
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
kvm reloads the host's fs and gs blindly, however the underlying segment
descriptors may be invalid due to the user modifying the ldt after loading
them.
Fix by using the safe accessors (loadsegment() and load_gs_index()) instead
of home grown unsafe versions.
This is CVE-2010-3698.
KVM-Stable-Tag.
Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/radeon/kms: avivo cursor workaround applies to evergreen as well
|
| | |/ / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Fixes cursor corruption in certain cases.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus:
MIPS: Enable ISA_DMA_API config to fix build failure
MIPS: 32-bit: Fix build failure in asm/fcntl.h
MIPS: Remove all generated vmlinuz* files on "make clean"
MIPS: do_sigaltstack() expects userland pointers
MIPS: Fix error values in case of bad_stack
MIPS: Sanitize restart logics
MIPS: secure_computing, syscall audit: syscall number should in r2, not r0.
MIPS: Don't block signals if we'd failed to setup a sigframe
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Add ISA_DMA_API config item and select it when GENERIC_ISA_DMA enabled.
This fixes build failure on allmodconfig like following:
CC sound/isa/es18xx.o
sound/isa/es18xx.c: In function 'snd_es18xx_playback1_prepare':
sound/isa/es18xx.c:501:9: error: implicit declaration of function 'snd_dma_program'
sound/isa/es18xx.c: In function 'snd_es18xx_playback_pointer':
sound/isa/es18xx.c:818:3: error: implicit declaration of function 'snd_dma_pointer'
make[3]: *** [sound/isa/es18xx.o] Error 1
make[2]: *** [sound/isa/es18xx.o] Error 2
make[1]: *** [sub-make] Error 2
make: *** [all] Error 2
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Cc: linux-mips@linux-mips.org
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/1717/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
CC security/integrity/ima/ima_fs.o
In file included from linux/include/linux/fcntl.h:4:0,
from linux/security/integrity/ima/ima_fs.c:18:
linux/arch/mips/include/asm/fcntl.h:63:2: error: expected specifier-qualifier-list before 'off_t'
make[3]: *** [security/integrity/ima/ima_fs.o] Error 1
make[2]: *** [security/integrity/ima/ima_fs.o] Error 2
make[1]: *** [sub-make] Error 2
make: *** [all] Error 2
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/1715/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
[Ralf: I changed the patch to explicitly list all files to be deleted out
of paranoia.]
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com>
Patchwork: http://patchwork.linux-mips.org/patch/1590/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
o32 compat does the right thing, native and n32 compat do not...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Cc: linux-kernel@vger.kernel.org
Cc: linux-arch@vger.kernel.org
Cc: linux-mips@linux-mips.org
Patchwork: http://patchwork.linux-mips.org/patch/1700/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|