12 Nov, 2010
1 commit
-
The size calculation is done incorrectly here because it should include
both the start and end (end - start + 1). It's easiest to just use
resource_size() which does the right thing.I was worried there was something non-standard going on because the
printk() subtracts "end - 1", but the rest of the file uses the normal
resource size calculations. This function is only called from
fsl_rio_setup() in arch/powerpc/sysdev/fsl_rio.c and the calculation
there is also:port->iores.start = law_start;
port->iores.end = law_start + law_size - 1;So I think this is the correct fix.
Signed-off-by: Dan Carpenter
Cc: Alexandre Bounine
Acked-by: Li Yang
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
28 Oct, 2010
12 commits
-
Replace possibly damaging broadcast writes into the per-port SP_MODE
registers with individual writes for each port. This will preserve
individual port configurations in case if ports are configured
differently.Signed-off-by: Alexandre Bounine
Cc: Kumar Gala
Cc: Matt Porter
Cc: Li Yang
Cc: Thomas Moll
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Replace hardcoded maximum port number with actual reported number of
switch ports.Signed-off-by: Alexandre Bounine
Cc: Kumar Gala
Cc: Matt Porter
Cc: Li Yang
Cc: Thomas Moll
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
RapidIO spec v.2.1 adds Idle Sequence 2 into LP-Serial Physical Layer.
The fix ensures that corresponding bits are not corrupted during error
handling.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Detects RIO link to the already enumerated device and properly sets links
between device objects. Changes to the enumeration/discovery logic:1. Use Master Enable bit to signal end of the enumeration - agents may
start their discovery process as soon as they see this bit set
(Component Tag register was used before for this purpose).2. Enumerator sets Component Tag (!= 0) immediately during device
setup. This allows to identify the device if the redundant route
exists in a RIO system.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add the RIO switch driver and definitions for IDT CPS-1848 and CPS-1616
Gen2 devices.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add explicit device access check before performing device enumeration.
This gives a chance to clear possible link error conditions by issuing
safe maintenance read request(s).Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add check for access to port-write (PW) message source device before
processing the PW message. If source RIO device is not available (power
down or RIO link failure) trace back to a last available switch/port on
the PW message route and service failure at that point.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
1. Change to create attribute "routes" only for switches.
2. Add a switch-specific callback to create/remove proprietary attributes.
Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The default error-stopped state handler provides recovery mechanism as
defined by RIO specification.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Create back and forward links between RIO devices. These links are
intended for use by error management and hot-plug extensions. Links for
redundant RIO connections between switches are not set (will be fixed in a
separate patch).Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The switch port information is obtained and stored during RIO device
setup. Therefore repeated reads from Switch Port Information CAR may be
removed.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This set of RapidIO patches extends support for standard error recovery
mechanism and adds new IDT Gen2 sRIO switch devices - CPS-1848 and
CPS-1616. Implementation of the standard error-stopped state recovery
mechanism (as defined by the RapidIO specification) is required for the
new switches.Version 2 of this set of patches addresses received comments and fixes an
error notification setup issue found in the idt_gen2.c after the first
version was released.This patch:
Make RapidIO devices appear in /sys/devices/rapidio directory instead of
top of /sys/devices directory.Signed-off-by: Alexandre Bounine
Cc: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Micha Nelissen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
17 Jun, 2010
1 commit
-
Signed-off-by: Uwe Kleine-König
Signed-off-by: Jiri Kosina
31 May, 2010
1 commit
-
Fix a bunch of new rapidio kernel-doc warnings:
Warning(include/linux/rio.h:123): No description found for parameter 'comp_tag'
Warning(include/linux/rio.h:123): No description found for parameter 'phys_efptr'
Warning(include/linux/rio.h:123): No description found for parameter 'em_efptr'
Warning(include/linux/rio.h:123): No description found for parameter 'pwcback'
Warning(include/linux/rio.h:247): No description found for parameter 'set_domain'
Warning(include/linux/rio.h:247): No description found for parameter 'get_domain'
Warning(drivers/rapidio/rio-scan.c:1133): No description found for parameter 'rdev'
Warning(drivers/rapidio/rio-scan.c:1133): Excess function parameter 'port' description in 'rio_init_em'
Warning(drivers/rapidio/rio.c:349): No description found for parameter 'rdev'
Warning(drivers/rapidio/rio.c:349): Excess function parameter 'mport' description in 'rio_request_inb_pwrite'
Warning(drivers/rapidio/rio.c:393): No description found for parameter 'port'
Warning(drivers/rapidio/rio.c:393): No description found for parameter 'local'
Warning(drivers/rapidio/rio.c:393): No description found for parameter 'destid'
Warning(drivers/rapidio/rio.c:393): No description found for parameter 'hopcount'
Warning(drivers/rapidio/rio.c:393): Excess function parameter 'rdev' description in 'rio_mport_get_physefb'
Warning(drivers/rapidio/rio.c:845): Excess function parameter 'local' description in 'rio_std_route_clr_table'Signed-off-by: Randy Dunlap
Cc: Alexandre Bounine
Signed-off-by: Linus Torvalds
28 May, 2010
9 commits
-
Fix to use correct default value for routing table entries.
Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Thomas Moll
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add switch specific domain routines required for 16-bit routing support in
switches with hierarchical implementation of routing tables.Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Thomas Moll
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Modify the way how RapidIO switch operations are declared. Multiple
assignments through the linker script replaced by single initialization
call.Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Thomas Moll
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add debug configuration option for RapidIO subsystem.
Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Thomas Moll
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Cc: Thomas Moll
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add the functionality to enable Input receiver and Output transmitter of
every port, to allow non-maintenance traffic.Signed-off-by: Thomas Moll
Signed-off-by: Alexandre Bounine
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add RapidIO Port-Write message handling in the context of Error
Management Extensions Specification Rev.1.3.Signed-off-by: Alexandre Bounine
Tested-by: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Add switch access locking during RapidIO discovery. Access lock is
required when reading switch routing table contents due to indexed
mechanism of RT addressing.Signed-off-by: Alexandre Bounine
Tested-by: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Extentions to RapidIO switch support:
1. modify switch route operation declarations to allow using single
switch-specific file for family of switches that share the same route
table operations.2. add standard route table operations for switches that that support
route table manipulation registers as defined in the Rev.1.3 of RapidIO
specification.3. add clear-route-table operation for switches
4. add CPSxx and TSIxxx families of RapidIO switches
Signed-off-by: Alexandre Bounine
Tested-by: Thomas Moll
Cc: Matt Porter
Cc: Li Yang
Cc: Kumar Gala
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
22 May, 2010
1 commit
-
This allows bin_attr->read,write,mmap callbacks to check file specific data
(such as inode owner) as part of any privilege validation.Signed-off-by: Chris Wright
Signed-off-by: Greg Kroah-Hartman
16 Jun, 2009
1 commit
-
Adding failure path for the following two cases.
warning: ignoring return value of 'device_add', declared with attribute warn_unused_result
warning: ignoring return value of 'sysfs_create_bin_file', declared with attribute warn_unused_resultSigned-off-by: Li Yang
Signed-off-by: Kumar Gala
19 May, 2009
1 commit
-
Signed-off-by: Li Yang
Signed-off-by: Kumar Gala
07 Apr, 2009
1 commit
-
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)
Signed-off-by: Yang Hongyang
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
25 Mar, 2009
1 commit
-
Cc: mporter@kernel.crashing.org
Acked-by: Greg Kroah-Hartman
Signed-off-by: Kay Sievers
07 Jan, 2009
1 commit
-
Remove excess kernel-doc notation from rio header and driver:
Warning(include/linux/rio_drv.h:399): Excess function parameter or struct member 'buffer' description in 'rio_get_inb_message'
Signed-off-by: Randy Dunlap
Cc: Matt Porter
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
16 Dec, 2008
1 commit
-
Cc: Matt Porter
Signed-off-by: Kay Sievers
Signed-off-by: Greg Kroah-Hartman
Signed-off-by: Paul Mackerras
01 Dec, 2008
1 commit
-
functions calling devinit and called only from devinit
Signed-off-by: Al Viro
Signed-off-by: Linus Torvalds
11 Jul, 2008
1 commit
-
Fix RapidIO device reference counting.
Signed-of-by: Eugene Surovegin
Cc: Matt Porter
Cc:
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
29 Apr, 2008
2 commits
-
The RapidIO system size will auto probe in RIO setup. The route table
and rionet_active in rionet.c are changed to be allocated dynamically
according to the size of the system.Signed-off-by: Zhang Wei
Signed-off-by: Andrew Morton
Signed-off-by: Paul Mackerras -
The original RapidIO driver suppose there is only one mpc85xx RIO controller
in system. So, some data structures are defined as mpc85xx_rio global, such
as 'regs_win', 'dbell_ring', 'msg_tx_ring'. Now, I changed them to mport's
private members. And you can define multi RIO OF-nodes in dts file for multi
RapidIO controller in one processor, such as PCI/PCI-Ex host controllers in
Freescale's silicon. And the mport operation function declaration should be
changed to know which RapidIO controller is target.Signed-off-by: Zhang Wei
Signed-off-by: Andrew Morton
Signed-off-by: Paul Mackerras
04 Mar, 2008
1 commit
-
Fix docbook problems in rapidio source files.
These cause the generated docbook to be incorrect.Signed-off-by: Randy Dunlap
Signed-off-by: Linus Torvalds
31 Jan, 2008
1 commit
29 Jan, 2008
1 commit
-
Remove the deprecated __attribute_used__.
[Introduce __section in a few places to silence checkpatch /sam]
Signed-off-by: Adrian Bunk
Signed-off-by: Sam Ravnborg
24 Jan, 2008
1 commit
-
drivers/rapidio/rio.c: In function 'rio_get_asm':
drivers/rapidio/rio.c:413: error: implicit declaration of function 'in_interrupt'
drivers/rapidio/rio.c: In function 'rio_init_mports':
drivers/rapidio/rio.c:480: warning: format '%8.8lx' expects type 'long unsigned int', but argument 2 has type 'resource_size_t'
drivers/rapidio/rio.c:480: warning: format '%8.8lx' expects type 'long unsigned int', but argument 3 has type 'resource_size_t'Signed-off-by: Kumar Gala
20 Jul, 2007
1 commit
-
Transform some calls to kmalloc/memset to a single kzalloc (or kcalloc).
Here is a short excerpt of the semantic patch performing
this transformation:@@
type T2;
expression x;
identifier f,fld;
expression E;
expression E1,E2;
expression e1,e2,e3,y;
statement S;
@@x =
- kmalloc
+ kzalloc
(E1,E2)
... when != \(x->fld=E;\|y=f(...,x,...);\|f(...,x,...);\|x=E;\|while(...) S\|for(e1;e2;e3) S\)
- memset((T2)x,0,E1);@@
expression E1,E2,E3;
@@- kzalloc(E1 * E2,E3)
+ kcalloc(E1,E2,E3)[akpm@linux-foundation.org: get kcalloc args the right way around]
Signed-off-by: Yoann Padioleau
Cc: Richard Henderson
Cc: Ivan Kokshaysky
Acked-by: Russell King
Cc: Bryan Wu
Acked-by: Jiri Slaby
Cc: Dave Airlie
Acked-by: Roland Dreier
Cc: Jiri Kosina
Acked-by: Dmitry Torokhov
Cc: Benjamin Herrenschmidt
Acked-by: Mauro Carvalho Chehab
Acked-by: Pierre Ossman
Cc: Jeff Garzik
Cc: "David S. Miller"
Acked-by: Greg KH
Cc: James Bottomley
Cc: "Antonino A. Daplas"
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds