summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2012-05-21Merge tag 'isci-for-3.5' into miscJames Bottomley749-6602/+8598
isci update for 3.5 1/ Rework remote-node-context (RNC) handling for proper management of the silicon state machine in error handling and hot-plug conditions. Further details below, suffice to say if the RNC is mismanaged the silicon state machines may lock up. 2/ Refactor the initialization code to be reused for suspend/resume support 3/ Miscellaneous bug fixes to address discovery issues and hardware compatibility. RNC rework details from Jeff Skirvin: In the controller, devices as they appear on a SAS domain (or direct-attached SATA devices) are represented by memory structures known as "Remote Node Contexts" (RNCs). These structures are transferred from main memory to the controller using a set of register commands; these commands include setting up the context ("posting"), removing the context ("invalidating"), and commands to control the scheduling of commands and connections to that remote device ("suspensions" and "resumptions"). There is a similar path to control RNC scheduling from the protocol engine, which interprets the results of command and data transmission and reception. In general, the controller chooses among non-suspended RNCs to find one that has work requiring scheduling the transmission of command and data frames to a target. Likewise, when a target tries to return data back to the initiator, the state of the RNC is used by the controller to determine how to treat the incoming request. As an example, if the RNC is in the state "TX/RX Suspended", incoming SSP connection requests from the target will be rejected by the controller hardware. When an RNC is "TX Suspended", it will not be selected by the controller hardware to start outgoing command or data operations (with certain priority-based exceptions). As mentioned above, there are two sources for management of the RNC states: commands from driver software, and the result of transmission and reception conditions of commands and data signaled by the controller hardware. As an example of the latter, if an outgoing SSP command ends with a OPEN_REJECT(BAD_DESTINATION) status, the RNC state will transition to the "TX Suspended" state, and this is signaled by the controller hardware in the status to the completion of the pending command as well as signaled in a controller hardware event. Examples of the former are included in the patch changelogs. Driver software is required to suspend the RNC in a "TX/RX Suspended" condition before any outstanding commands can be terminated. Failure to guarantee this can lead to a complete hardware hang condition. Earlier versions of the driver software did not guarantee that an RNC was correctly managed before I/O termination, and so operated in an unsafe way. Further, the driver performed unnecessary contortions to preserve the remote device command state and so was more complicated than it needed to be. A simplifying driver assumption is that once an I/O has entered the error handler path without having completed in the target, the requirement on the driver is that all use of the sas_task must end. Beyond that, recovery of operation is dependent on libsas and other components to reset, rediscover and reconfigure the device before normal operation can restart. In the driver, this simplifying assumption meant that the RNC management could be reduced to entry into the suspended state, terminating the targeted I/O request, and resuming the RNC as needed for device-specific management such as an SSP Abort Task or LUN Reset Management request.
2012-05-21drivers/net/stmmac: seq_file fix memory leakDjalal Harouni1-2/+2
Use single_release() instead of seq_release() to free memory allocated by single_open(). Signed-off-by: Djalal Harouni <tixxdz@opendz.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-21blackfin: fix build after add bf60x mach/pm.hSteven Miao2-1/+3
Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: twi: include linux/i2c.hSonic Zhang1-0/+1
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: add head file for crc controllerSonic Zhang1-0/+139
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: twi: work around temporary anomaly 0501001Sonic Zhang1-0/+27
Disable IRQ when reading MMR rcv_data8 and rcv_data16. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: twi: Move TWI MMR access macro to twi head fileSonic Zhang1-0/+44
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: twi: Move TWI peripheral pin request array to platform dataSonic Zhang17-1/+102
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: anomaly: Add a temporary anomaly 0501001Sonic Zhang2-0/+14
Add a temporary anomaly 0501001 for data loss in MMR reading if interrupted. Add work around for bfin serial driver as well. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: Rename the DDR controller macroSonic Zhang4-56/+56
Rename the DDR controller macro from DDR0 to DMC0 to avoid confustion for bf60x. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: mach-bf609: pm: cleanup bfin_deepsleepSteven Miao1-8/+7
In bfin_deepsleep(), using register instead of local variable and remove unused dpmc register read. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: cleanup get clock codeSonic Zhang1-42/+22
Remove redundance code for get clock. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: pm: Add a debug option to calculate kernel wakeup time.Sonic Zhang6-0/+74
Display the total time when kernel resumes normal from standby or suspend to mem mode. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: add wakeup source selectSteven Miao6-29/+192
Support select the wakeup source for power management on bf60x. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: make clock changeable in kernel menuconfigBob Liu5-29/+197
Add clock changeable support in kernel menuconfig for bf60x. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin:mach-bf609: fix norflash for bf609-ezkitBob Liu2-5/+6
Set smc register to async flash protocol mode and use physmap driver instead of bfin-bf6xx. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: mach-bf609: add can_wakeup to ethernet deviceBob Liu1-0/+1
Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: remove redundant CONFIG_BF60x macroSonic Zhang1-6/+0
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: rotary: Add pm_wakeup flag to platform data structure.Sonic Zhang4-0/+4
Rotary can't be used as a wakeup source in all platform. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21bfin_gpio: fix bf548-ezkit kernel fail to bootSteven Miao1-1/+2
Fix bf548-ezkit kernel fail to boot when request peripheral pins. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21bfin_dma: fix initcall return error in proc_dma_init()Steven Miao1-1/+2
Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21Blackfin: delete fork funcMike Frysinger3-12/+2
We don't implement fork() since we are no-mmu, so redirect it to the existing ENOSYS stub rather than adding a custom EINVAL one. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21Blackfin: fix unused clk var warningMike Frysinger1-0/+2
This is only used on BF60x code (so this patch should get squashed into the original one that added it). Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: SMP: pda: "next" field of blackfin_pda only used in SMP kernelSteven Miao1-0/+2
Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: GPIO: Implement more GPIO APIsSonic Zhang1-0/+44
Implement more GPIO APIs in case GPIOLIB is disabled. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: mach-common: ints-priority: fix compile errorBob Liu1-0/+2
IRQ_PINT4/PINT5 are not defined on !CONFIG_BF60x, this patch fix it. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: bfin_uart: Add more LCR bits masksSonic Zhang1-2/+4
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: license: Change ADI BSD licenseSonic Zhang53-100/+84
Change ADI BSD license to standart 3 clause BSD license for some blackfin arch code requested by ADI Legal. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf537-stamp: update board file for platform bfin_sport deviceAaron Wu2-8/+54
Blackfin sport driver has been rewrited update board file according. Signed-off-by: Aaron Wu <Aaron.Wu@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: cleanup mem_map macroSteven Miao1-3/+3
Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: fix compiling warningBob Liu3-3/+11
Fix several compiling warning for bf60x. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: add power management supportSteven Miao8-595/+1105
Add bf60x cpu pm callbacks and change blackfin pm framework to support bf60x. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: add l2 ecc irq handlerBob Liu1-0/+36
bf60x support l2 hardware ecc error check, add panic when double bits ecc error happened. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: twi: move twi bit mask macro to twi head fileSonic Zhang6-396/+70
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: enable gptimer clock sourceSteven Miao3-3/+211
Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: add spi/sport3/ppi head file for bf60xScott Jiang3-0/+493
Signed-off-by: Scott Jiang <scott.jiang.linux@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: cplb: add support for bf60xBob Liu4-2/+16
Bf60x support big CPLB pages, this commit enable it. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: mach-common: add sec support for bf60xSteven Miao2-39/+385
Add system event controller support for bf60x so that interrupt can be handled. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: bf60x: add clock supportSteven Miao6-2/+495
Add clock support for bf60x. Signed-off-by: Steven Miao <realmz6@gmail.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: add bf60x to current frameworkBob Liu19-146/+840
This patch added bf60x to current blackfin kernel framework. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: mach-bf609: add machine filesSonic Zhang20-0/+9781
Add machine files for bf60x including head files, Kconfig/Makefile and board file. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: asm: fix blackfin.h brokenBob Liu1-6/+2
do{...}while makes no sense in __ASSEMBLY__ code paths. now kernels fail to build: arch/blackfin/mach-bf561/atomic.S: Assembler messages: arch/blackfin/mach-bf561/atomic.S:48: Error: syntax error. Input text was do. arch/blackfin/mach-bf561/atomic.S:48: Error: arch/blackfin/mach-bf561/atomic.S:48: Error: syntax error. Input text was }. arch/blackfin/mach-bf561/atomic.S:48: Error: arch/blackfin/mach-bf561/atomic.S:53: Error: syntax error. Input text was do. arch/blackfin/mach-bf561/atomic.S:53: Error: arch/blackfin/mach-bf561/atomic.S:53: Error: syntax error. Input text was }. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-21blackfin: configs: add SMP support back to BF561-EZKIT-SMP_defconfigBob Liu1-3/+1
SMP support was removed from BF561-EZKIT-SMP_defconfig in last commit by mistake, this patch add it back. Signed-off-by: Bob Liu <lliubbo@gmail.com>
2012-05-20Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller60-260/+514
2012-05-20iscsi-target: Fix iov_count calculation bug in iscsit_allocate_iovecsNicholas Bellinger1-1/+1
This patch fixes a bug in iscsit_allocate_iovecs() where iov_count was incorrectly calculated using min(1UL, data_length / PAGE_SIZE) instead of max(1UL, data_length / PAGE_SIZE), that ends up triggering an OOPs for large block I/O when the SGL <-> iovec mapping exceeds the bogus iov_count allocation size. This is a regression introduced during the iscsi-target conversion back to using core memory allocation here: commit bfb79eac2026b411df9e253a9c350039b4b04bb7 Author: Andy Grover <agrover@redhat.com> Date: Tue Apr 3 15:51:29 2012 -0700 target/iscsi: Go back to core allocating data buffer for cmd Cc: Andy Grover <agrover@redhat.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
2012-05-20Linux 3.4v3.4Linus Torvalds1-1/+1
2012-05-20ipv6/exthdrs: strict Pad1 and PadN checkEldad Zack1-1/+14
The following tightens the padding check from commit c1412fce7eccae62b4de22494f6ab3ff8a90c0c6 : * Take into account combinations of consecutive Pad1 and PadN. * Catch the corner case of when only padding is present in the header, when the extention header length is 0 (i.e., 8 bytes). In this case, the header would have exactly 6 bytes of padding: +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ : Next Header : Hdr Ext Len=0 : : +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ + : Padding (Pad1 or PadN) : +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Signed-off-by: Eldad Zack <eldad@fogrefinery.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-20USB: qmi_wwan: Add ZTE (Vodafone) K3520-ZAndrew Bird (Sphere Systems)1-0/+18
Signed-off-by: Andrew Bird <ajb@spheresystems.co.uk> Acked-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-20USB: qmi_wwan: Add ZTE (Vodafone) K3765-ZAndrew Bird (Sphere Systems)1-0/+9
Add the ZTE (Vodafone) K3765-Z to the whitelist. This requires the previous patch to make the whitelist with forced interface 4 generic or the device fails to initialise. After applying this patch and loading the Option driver without usb-modeswitch's bind all interfaces trick, a wwan0 net interface and /dev/cdc-wdm0 device file were created. Using Bjorn Mork's perl connection script a connection was made to a mobile network using QMI and the network interface's IPv4 address was configured OK. Signed-off-by: Andrew Bird <ajb@spheresystems.co.uk> Acked-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-05-20USB: qmi_wwan: Make forced int 4 whitelist genericAndrew Bird (Sphere Systems)1-2/+2
Change the forced interface 4 whitelist to use the generic shared binder instead of the Gobi specific one. Certain ZTE devices (K3520-Z & K3765-Z) don't work with the Gobi version, but function quite happily with the generic. This has been tested with the following devices: K3520-Z K3565-Z K3765-Z K4505-Z It hasn't been tested with the ZTE MF820D, which is the only other device that uses this whitelist at present. Although Bjorn doesn't expect any problems, any testing with that device would be appreciated. Signed-off-by: Andrew Bird <ajb@spheresystems.co.uk> Acked-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: David S. Miller <davem@davemloft.net>