Age | Commit message (Collapse) | Author | Files | Lines |
|
The basic scheme of the block mode assembler is that we start by
enabling the FPU, loading the key into the floating point registers,
then iterate calling the encrypt/decrypt routine for each block.
For the 256-bit key cases, we run short on registers in the unrolled
loops.
So the {ENCRYPT,DECRYPT}_256_2() macros reload the key registers that
get clobbered.
The unrolled macros, {ENCRYPT,DECRYPT}_256(), are not mindful of this.
So if we have a mix of multi-block and single-block calls, the
single-block unrolled 256-bit encrypt/decrypt can run with some
of the key registers clobbered.
Handle this by always explicitly loading those registers before using
the non-unrolled 256-bit macro.
This was discovered thanks to all of the new test cases added by
Jussi Kivilinna.
Signed-off-by: David S. Miller <[email protected]>
|
|
Signed-off-by: Al Viro <[email protected]>
|
|
note that they are relying on access_ok() already checked by caller.
Signed-off-by: Al Viro <[email protected]>
|
|
Again, conditional on CONFIG_GENERIC_SIGALTSTACK
Signed-off-by: Al Viro <[email protected]>
|
|
Conditional on CONFIG_GENERIC_SIGALTSTACK; architectures that do not
select it are completely unaffected
Signed-off-by: Al Viro <[email protected]>
|
|
Compat counterpart of current_user_stack_pointer(); for most of the biarch
architectures those two are identical, but e.g. arm64 and arm use different
registers for stack pointer...
Note that amd64 variants of current_user_stack_pointer/compat_user_stack_pointer
do *not* rely on pt_regs having been through FIXUP_TOP_OF_STACK.
Signed-off-by: Al Viro <[email protected]>
|
|
to be used by rt_sigreturn instances
Signed-off-by: Al Viro <[email protected]>
|
|
Signed-off-by: Al Viro <[email protected]>
|
|
Cross-architecture equivalent of rdusp(); default is
user_stack_pointer(current_pt_regs()) - that works for almost all
platforms that have usp saved in pt_regs. The only exception from
that is ia64 - we want memory stack, not the backing store for
register one.
Signed-off-by: Al Viro <[email protected]>
|
|
for the architectures that have usp in pt_regs and do not have
user_stack_pointer() already defined.
Signed-off-by: Al Viro <[email protected]>
|
|
All architectures have
CONFIG_GENERIC_KERNEL_THREAD
CONFIG_GENERIC_KERNEL_EXECVE
__ARCH_WANT_SYS_EXECVE
None of them have __ARCH_WANT_KERNEL_EXECVE and there are only two callers
of kernel_execve() (which is a trivial wrapper for do_execve() now) left.
Kill the conditionals and make both callers use do_execve().
Signed-off-by: Al Viro <[email protected]>
|
|
Signed-off-by: Al Viro <[email protected]>
|
|
The FPGA can't handled unaligned DMA (yet). So copy into an aligned buffer,
if skb->data isn't suitably aligned.
Signed-off-by: David Woodhouse <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
Signed-off-by: Nathan Williams <[email protected]>
Signed-off-by: David Woodhouse <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
Signed-off-by: Nathan Williams <[email protected]>
Signed-off-by: David Woodhouse <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
dwmw2: Tidy up a little, simpler matching on which GPIO is being accessed,
only register on newer boards, register under PCI device instead of
duplicating them under each ATM device.
Signed-off-by: Nathan Williams <[email protected]>
Signed-off-by: David Woodhouse <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
commit: cb64edb6b89491edfdbae52ba7db9a8b8391d339 upstream
Above commit may introduce a race between cp_interrupt and dev_close
/ change MTU / dev_open up state. Changes cp_interrupt to tolerate
this. Change spin_locking in cp_interrupt to avoid possible
but unobserved race.
Reported-by: "Francois Romieu" <[email protected]>
Tested on virtual hardware, Tx MTU size up to 4096, max tx payload
was ping -s 4068 for MTU of 4096. No real hardware, need test
assist.
Signed-off-by: "John Greene" <[email protected]>
CC: "David S. Miller" <[email protected]>
CC: "David Woodhouse" <[email protected]>
Tested-by: David Woodhouse <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
When building without device tree support (for the mv78x00 SoCs for
example), the build failed because of_irq_count is undeclared. However
mvebu-gpio is not designed to build without device tree support. So
make it depends on OF_CONFIG, remove the #ifdef OF_CONFIG line and the
platform_device_id.
Tested on RD-78x00-mASA, DB-78460-BP, DB-88F6710-BP-DDR3,
DB-MV784MP-GP, Mirabox and OpenBlocks AX3.
Signed-off-by: Gregory CLEMENT <[email protected]>
Signed-off-by: Grant Likely <[email protected]>
|
|
As reported by CONFIG_DEBUG_SPINLOCK=y.
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Peter Tyser <[email protected]>
Signed-off-by: Grant Likely <[email protected]>
|
|
Fix regression introduced by 85b144f860176
"drm/ttm: call ttm_bo_cleanup_refs with reservation and lru lock held, v3"
Slowpath ttm_bo_cleanup_refs_and_unlock accidentally tried to increase
refcount on &bo->sync_obj instead of bo->sync_obj.
The compiler didn't complain since sync_obj_ref takes a void pointer,
so it was still valid c.
This could result in lockups, memory corruptions, and warnings like
these when graphics card VRAM usage is high:
------------[ cut here ]------------
WARNING: at include/linux/kref.h:42 radeon_fence_ref+0x2c/0x40()
Hardware name: System Product Name
Pid: 157, comm: X Not tainted 3.7.0-rc7-00520-g85b144f-dirty #174
Call Trace:
[<ffffffff81058c84>] ? warn_slowpath_common+0x74/0xb0
[<ffffffff8129273c>] ? radeon_fence_ref+0x2c/0x40
[<ffffffff8125e95c>] ? ttm_bo_cleanup_refs_and_unlock+0x18c/0x2d0
[<ffffffff8125f17c>] ? ttm_mem_evict_first+0x1dc/0x2a0
[<ffffffff81264452>] ? ttm_bo_man_get_node+0x62/0xb0
[<ffffffff8125f4ce>] ? ttm_bo_mem_space+0x28e/0x340
[<ffffffff8125fb0c>] ? ttm_bo_move_buffer+0xfc/0x170
[<ffffffff810de172>] ? kmem_cache_alloc+0xb2/0xc0
[<ffffffff8125fc15>] ? ttm_bo_validate+0x95/0x110
[<ffffffff8125ff7c>] ? ttm_bo_init+0x2ec/0x3b0
[<ffffffff8129419a>] ? radeon_bo_create+0x18a/0x200
[<ffffffff81293e80>] ? radeon_bo_clear_va+0x40/0x40
[<ffffffff812a5342>] ? radeon_gem_object_create+0x92/0x160
[<ffffffff812a575c>] ? radeon_gem_create_ioctl+0x6c/0x150
[<ffffffff812a529f>] ? radeon_gem_object_free+0x2f/0x40
[<ffffffff81246b60>] ? drm_ioctl+0x420/0x4f0
[<ffffffff812a56f0>] ? radeon_gem_pwrite_ioctl+0x20/0x20
[<ffffffff810f53a4>] ? do_vfs_ioctl+0x2e4/0x4e0
[<ffffffff810e5588>] ? vfs_read+0x118/0x160
[<ffffffff810f55ec>] ? sys_ioctl+0x4c/0xa0
[<ffffffff810e5851>] ? sys_read+0x51/0xa0
[<ffffffff814b0612>] ? system_call_fastpath+0x16/0x1b
Signed-off-by: Maarten Lankhorst <[email protected]>
Reported-by: Markus Trippelsdorf <[email protected]>
Acked-by: Paul Menzel <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
|
|
With commit c7d3df3 "mei: use internal watchdog device registration
tracking" will crash the kernel on shutdown path on systems
where ME watchdog is not present.
Since the watchdog was never initialized in such case
the WDOG_UNREGISTERED bit is never set and the system
crashes on access to uninitialized variables down the path.
To solve the issue we query for NULL on watchdog driver driver_data
to check whether the device is registered. This is handled in the
driver and doesn't depend on watchdog core internals.
Cc: Borislav Petkov <[email protected]>
Cc: Wanlong Gao <[email protected]>
Signed-off-by: Jerry Snitselaar <[email protected]>
Signed-off-by: Tomas Winkler <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
If the DT does not include a regs parameter then the null res
would be dereferenced.
Signed-off-by: Jason Gunthorpe <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
The current sp5100_tco driver only supports SP5100/SB7x0 chipset, doesn't
support SB8x0 chipset, because current sp5100_tco driver doesn't know that the
offset address for watchdog timer was changed from SB8x0 chipset.
The offset address of SP5100 and SB7x0 chipsets are as follows, quote from the
AMD SB700/710/750 Register Reference Guide (Page 164) and the AMD SP5100
Register Reference Guide (Page 166).
WatchDogTimerControl 69h
WatchDogTimerBase0 6Ch
WatchDogTimerBase1 6Dh
WatchDogTimerBase2 6Eh
WatchDogTimerBase3 6Fh
In contrast, the offset address of SB8x0 chipset is as follows, quote from
AMD SB800-Series Southbridges Register Reference Guide (Page 147).
WatchDogTimerEn 48h
WatchDogTimerConfig 4Ch
So, In the case of SB8x0 chipset, sp5100_tco reads meaningless MMIO
address (for example, 0xbafe00) from wrong offset address, and the following
message is logged.
SP5100 TCO timer: mmio address 0xbafe00 already in use
With this patch, sp5100_tco driver supports SB8x0 chipset, and can avoid
iomem resource conflict. The processing of this patch is as follows.
Step 1) Attempt to get the watchdog base address from indirect I/O (0xCD6
and 0xCD7).
- Go to the step 7 if obtained address hasn't conflicted with other
resource. But, currently, the address (0xfec000f0) conflicts with the
IOAPIC MMIO address, and the following message is logged.
SP5100 TCO timer: mmio address 0xfec000f0 already in use
0xfec000f0 is recommended by AMD BIOS Developer's Guide. So, go to the
next step.
Step 2) Attempt to get the SBResource_MMIO base address from AcpiMmioEN (for
SB8x0, PM_Reg:24h) or SBResource_MMIO (SP5100/SB7x0, PCI_Reg:9Ch)
register.
- Go to the step 7 if these register has enabled by BIOS, and obtained
address hasn't conflicted with other resource.
- If above condition isn't true, go to the next step.
Step 3) Attempt to get the free MMIO address from allocate_resource().
- Go to the step 7 if these register has enabled by BIOS, and obtained
address hasn't conflicted with other resource.
- Driver initialization has failed if obtained address has conflicted
with other resource, and no 'force_addr' parameter is specified.
Step 4) Use the specified address If 'force_addr' parameter is specified.
- allocate_resource() function may fail, when the PCI bridge device occupies
iomem resource from 0xf0000000 to 0xffffffff. To handle such a case,
I added 'force_addr' parameter to sp5100_tco driver. With 'force_addr'
parameter, sp5100_tco driver directly can assign MMIO address for watchdog
timer from free iomem region. Note that It's dangerous to specify wrong
address in the 'force_addr' parameter.
Example of force_addr parameter use
# cat /proc/iomem
...snip...
fec00000-fec003ff : IOAPIC 0
<--- free MMIO region
fec10000-fec1001f : pnp 00:0b
fec20000-fec203ff : IOAPIC 1
...snip...
# cat /etc/modprobe.d/sp5100_tco.conf
options sp5100_tco force_addr=0xfec00800
# modprobe sp5100_tco
# cat /proc/iomem
...snip...
fec00000-fec003ff : IOAPIC 0
fec00800-fec00807 : SP5100 TCO <--- watchdog timer MMIO address
fec10000-fec1001f : pnp 00:0b
fec20000-fec203ff : IOAPIC 1
...snip...
#
- Driver initialization has failed if specified address has conflicted
with other resource.
Step 5) Disable the watchdog timer
- To rewrite the watchdog timer register of the chipset, absolutely
guarantee that the watchdog timer is disabled.
Step 6) Re-program the watchdog timer MMIO address to chipset.
- Re-program the obtained MMIO address in Step 3 or Step 4 to chipset via
indirect I/O (0xCD6 and 0xCD7).
Step 7) Enable and setup the watchdog timer
This patch has worked fine on my test environment (ASUS M4A89GTD-PRO/USB3 and
DL165G7). therefore I believe that it's no problem to re-program the MMIO
address for watchdog timer to chipset during disabled watchdog. However,
I'm not sure about it, because I don't know much about chipset programming.
So, any comments will be welcome.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=43176
Tested-by: Arkadiusz Miskiewicz <[email protected]>
Tested-by: Paul Menzel <[email protected]>
Signed-off-by: Takahisa Tanaka <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
This adds OF support for davinci_wdt driver.
Signed-off-by: Murali Karicheri <[email protected]>
Acked-by: Grant Likely <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
It is not required to free devm_ allocated data. Since kref_put
needs a valid release function, da9052_wdt_release_resources()
is not deleted.
Fixes following warning.
drivers/watchdog/da9052_wdt.c:59:1-6: WARNING: invalid free of
devm_ allocated data
Signed-off-by: Tushar Behera <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
TWL_MODULE_PM_RECEIVER
To facilitate upcoming cleanup in twl stack.
No functional changes.
Signed-off-by: Peter Ujfalusi <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
The CONFIG_EXPERIMENTAL config item has not carried much meaning for a
while now and is almost always enabled by default. As agreed during the
Linux kernel summit, remove it from any "depends on" lines in Kconfigs.
Signed-off-by: Kees Cook <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
dev_<level> calls take less code than dev_printk(KERN_<LEVEL>
and reducing object size is good.
Signed-off-by: Joe Perches <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
This is the Watchdog patch for the DA9055 PMIC. This patch has got dependency on
the DA9055 MFD core.
This patch is functionally tested on SMDK6410
Signed-off-by: David Dajun Chen <[email protected]>
Signed-off-by: Ashish Jangam <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Eliminate a goto to simplify the code.
Signed-off-by: Aaro Koskinen <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
It's not needed to manually reset the driver data.
Signed-off-by: Aaro Koskinen <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Use devm_kzalloc(), devm_request_mem_region() ande devm_ioremap()
to simplify the code.
Signed-off-by: Aaro Koskinen <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Convert omap_wdt to new watchdog core. On OMAP boards, there are usually
multiple watchdogs. Since the new watchdog core supports multiple
watchdogs, all watchdog drivers used on OMAP should be converted.
The legacy watchdog device node is still created, so this should not
break existing users.
Signed-off-by: Aaro Koskinen <[email protected]>
Tested-by: Jarkko Nikula <[email protected]>
Tested-by: Lokesh Vutla <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Signed-off-by: Fabio Porcedda <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Convert clk_enable/clk_disable to clk_prepare_enable/clk_disable_unprepare
calls as required by common clock framework.
Signed-off-by: Thomas Abraham <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
With device tree support in place, we should not use IMX_HAVE_PLATFORM_IMX2_WDT
as a dependency for selecting the imx2_wdt driver.
Use ARCH_MXC symbol instead, so that the driver can be even selected by a device-tree
only SoC, such as i.MX6.
Signed-off-by: Fabio Estevam <[email protected]>
Acked-by: Shawn Guo <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
We do a setup_timer at init stage of the module, but we didn't
de-activate the time using del_timer.
Signed-off-by: devendra.aaru <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Changing the version of the driver for all the latest patches being applied
for kdump fixes.
Signed-off-by: Thomas Mingarelli <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Convert the twl4030_wdt watchdog driver to watchdog core.
While at there use devm_kzalloc and set the default timeout in order to be
able test this driver with a simple shell script.
Signed-off-by: Jarkko Nikula <[email protected]>
Tested-by: Aaro Koskinen <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
As a first step towards migrating davinci platforms to use common clock
framework, replace all instances of clk_enable() with clk_prepare_enable()
and clk_disable() with clk_disable_unprepare(). Until the platform is
switched to use the CONFIG_HAVE_CLK_PREPARE Kconfig variable, this just
adds a might_sleep() call and would work without any issues.
This will make it easy later to switch to common clk based implementation
of clk driver from DaVinci specific driver.
Signed-off-by: Murali Karicheri <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Clk_prepare_enable and clk_disable_unprepare combine clk_prepare and
clk_enable, and clk_disable and clk_unprepare. They make the code more
concise, and ensure that clk_unprepare is called when clk_enable fails.
A simplified version of the semantic patch that introduces calls to these
functions is as follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
expression e;
@@
- clk_prepare(e);
- clk_enable(e);
+ clk_prepare_enable(e);
@@
expression e;
@@
- clk_disable(e);
- clk_unprepare(e);
+ clk_disable_unprepare(e);
// </smpl>
Signed-off-by: Julia Lawall <[email protected]>
Acked-by: Viresh Kumar <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
This makes the code a bit smaller by getting rid of
some boilerplate code.
Signed-off-by: Gabor Juhos <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
|
|
Since family 11h processors, AMD is exclusively using 7-bit VID codes
transmitted using a serial protocol over two pins (clock and data.)
Signed-off-by: Jean Delvare <[email protected]>
Tested-by: David Hubbard <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
|
|
Extend support for reporting and selecting PECI temperature sensors
to IT8718, IT8720, IT8782, and IT8783. For IT8721, report the sensor
type for temp2 as Intel PECI (6) if the chip is configured to report
the PCH temperature.
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
IT8721 and IT8728 support Intel PECI temperature reporting. Each sensor
can be programmed to display the temperature reported on the PECI interface.
If configured for Intel PECI, the driver reported the wrong sensor type for
the respective thermal sensor. Fix the code to correctly report it as
"Intel PECI (6)".
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
This simplifies the code, improves runtime performance, reduces
code size (about 280 bytes on x86_64), and makes it easier
to add support for new devices.
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
Fix checkpatch error:
ERROR: Macros with multiple statements should be enclosed in a do - while loop
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
Fix the respective checkpatch warnings.
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
Also unify fan functions to use the same code for 8 and 16 bit fans.
This patch reduces code size by approximately 1,200 bytes on x86_64.
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|
|
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
|