aboutsummaryrefslogtreecommitdiff
path: root/sys/mips/rmi/dev/xlr/rge.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove rge driver from Broadcom XLRSean Bruno2015-09-041-2564/+0
| | | | | | | | | | | | | | | nlge(4) is supposed to deprecate rge(4) for Broadcom XLR when it was introduced 5 years ago. rge doesn't build on -CURRENT due to MII changes. All the XLR kernel confs use nlge. Let's get rid of the old driver for FreeBSD 11. We can use 10-STABLE or SVN to go back and look at the old driver if needed. Differential Revision: https://reviews.freebsd.org/D3339 Submitted by: kevin.bowling@kev009.com Notes: svn path=/head/; revision=287471
* CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than tenJung-uk Kim2015-05-221-2/+2
| | | | | | | | | | | | | years for head. However, it is continuously misused as the mpsafe argument for callout_init(9). Deprecate the flag and clean up callout_init() calls to make them more consistent. Differential Revision: https://reviews.freebsd.org/D2613 Reviewed by: jhb MFC after: 2 weeks Notes: svn path=/head/; revision=283291
* Mechanically convert to if_inc_counter().Gleb Smirnoff2014-09-191-2/+2
| | | | Notes: svn path=/head/; revision=271858
* Mechanically substitute flags from historic mbuf allocator withGleb Smirnoff2012-12-051-1/+1
| | | | | | | | | | | | malloc(9) flags within sys. Exceptions: - sys/contrib not touched - sys/mbuf.h edited manually Notes: svn path=/head/; revision=243882
* Remove duplicate header includesKevin Lo2011-06-261-2/+0
| | | | Notes: svn path=/head/; revision=223562
* Remove bogus usage of INTR_FAST. "Fast" interrupts are now indicated byJohn Baldwin2011-01-061-1/+1
| | | | | | | | registering a filter handler rather than a threaded handler. Also remove a bogus use of INTR_MPSAFE for a filter. Notes: svn path=/head/; revision=217072
* fix mips build breakage introduced in r216375: atomic_store_int doesn't existsAndriy Gapon2010-12-131-3/+1
| | | | | | | | | | | | | | | | 1) 32-bit assignment are expected to always be atomic. 2) Release/acquire memory barrier semantics doesn't seem to be needed here. So a simple assignment can be used. Remove unused port_set_counter() while here, it also used to mis-use atomic_set_int(). Reported by: jhb Pointyhat to: avg MFC after: 3 weeks Notes: svn path=/head/; revision=216408
* fix atomic_set_xxx misuse in rgeAndriy Gapon2010-12-111-2/+2
| | | | | | | | | | It seems that atomic_set_xxx and atomic_store_xxx were confused. Reviewed by: jhb (general issue) MFC after: 3 weeks Notes: svn path=/head/; revision=216375
* Update message ring handling code for XLR/XLSJayachandran C.2010-10-031-7/+10
| | | | | | | | | | | | | | - Wakeup multiple threads per core using message ring watermark interrupts. - Update message ring handler registration, use the real device station id for registering interrupts. - rge/nlge: update for the new message ring registration code. - rge/nlge: use 2 message ring stations for incoming packets, this will allow more messages to be queued. - nlge: comment fixes, remove unused variable - style and whitespace fixes Notes: svn path=/head/; revision=213377
* Network driver updates.Jayachandran C.2010-09-161-55/+11
| | | | | | | | | | | | | | | | | - Move RMI MIPS extension to atomic increment word (LDADDWU) to common header file sys/mips/rmi/rmi_mips_exts.h - Fix xlr_ldaddwu() for 64 bit, it is a 32 bit operation, use unsigned int* instead of unsigned long* argument - Provide dummy xlr_enable_kx/xlr_restore_kx for n32 and n64. - Provide xlr_paddr_ld() instead of xlr_paddr_lw(), so that the descriptor formats are same for 32 and 64 bit - update nlge and rge for the changes These changes are also needed by the security driver which will be added later. Notes: svn path=/head/; revision=212758
* sys/mips/rmi/msgring.h - fixes and clean up.Jayachandran C.2010-09-131-2/+2
| | | | | | | | | | | | | | - Remove sync from msgrng_send, sync needs to be called just once before sending. - Fix retry logic - don't reload registers when retrying in message_send, also fix check for send pending fail. - remove unused message_send_block_fast() - merge message_receive_fast() to message_receive - style(9) fixes, and comments - rge and nlge updated for the sys/mips/rmi/msgring.h changes Notes: svn path=/head/; revision=212553
* Compilation fix - when INVARIANTS are turned off.Jayachandran C.2010-09-101-1/+4
| | | | Notes: svn path=/head/; revision=212409
* Clean up fast message ring code for XLR.Jayachandran C.2010-09-081-41/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix message ring send path: - define msgrng_access_enable() which disables local interrupts and enables message ring access. Also define msgrng_restore() which restores interrupts - remove all other msgrng enable/disable macros, no need of critical_enter and other locking here. - message_send() fixup: re-read status until pending bit clears - message_send_retry() fixup: retry only few times with interrupts disabled - Fix up message_send/message_send_retry callers - call msgrng_access_enable() and msgrng_restore() correctly so that interrupts are not disabled for long. - removed unused and obsolete code from sys/mips/rmi/msgring.h - some style fixes - more later rge.c (XLR GMAC driver): - updated for the message ring changes - remove unused message_send_block() - retry on credit failure, this is not a permanent failure when credits are configured correctly. Add panic if credits are not available to send for a long time. Notes: svn path=/head/; revision=212321
* Move debug.h to the the rge driver directory. rge.c is the only user ofJayachandran C.2010-08-301-1/+2
| | | | | | | debug.h. Remove debug.h references from other files. Notes: svn path=/head/; revision=211996
* Clean up header files in RMI platform code (sys/mips/rmi), and removeJayachandran C.2010-08-301-12/+8
| | | | | | | | | | | | | | | | | | | unused files. - remove clock.c and clock.h, these are not used after the new timer code was added. - remove duplicated include files, fix header file ordering, remove some unneeded includes. - rename mips/rmi/shared_structs.h which contains the RMI boot loader interface to mips/rmi/rmi_boot_info.h. Remove unused files mips/rmi/shared_structs_func.h and sys/mips/rmi/shared_structs_offsets.h - merge mips/rmi/xlrconfig.h and mips/rmi/rmi_mips_exts.h, and remove duplicated functions. - nlge - minor change to remove unneeded argument. - Add FreeBSD svn keyword for headers Notes: svn path=/head/; revision=211994
* Update rge driver for 64 bit kernel.Jayachandran C.2010-07-291-14/+34
| | | | | | | | | - stored virtual addresses should be 64bit - physical memory can be directly accessed using XKPHYS pointers in 64 bit. - no need to enable KX Notes: svn path=/head/; revision=210630
* 64 bit compilation support XLR platform code.Jayachandran C.2010-07-081-18/+19
| | | | | | | | | | Mostly changes to make casting between int and pointer and printing 64bit values safe for 32 and 64 bit compile. Approved by: rrs Notes: svn path=/head/; revision=209808
* Add support for newer XLS chips/boards in the GMAC driver.Jayachandran C.2010-06-181-16/+37
| | | | | | | | | Improved processor id code in board.h, remove unnecessary macros. Approved by: rrs(mentor) Notes: svn path=/head/; revision=209318
* Changes to boot on a subset of threads on an XLR/XLS core.Jayachandran C.2010-05-211-5/+5
| | | | | | | | | | | | | | - Adds re-partitioning TLB per core for enabled threads. - Adds hardware thread id to cpuid mapping - updates rge driver packet distribution and message ring handling threads to be started based on hardware thread id. - remove unused early debugging code to set control registers. - coding style fixes Approved by: rrs (mentor) Notes: svn path=/head/; revision=208369
* Add a device description.Rui Paulo2010-05-181-0/+2
| | | | Notes: svn path=/head/; revision=208265
* This pushes all of JC's patches that I have in place. IRandall Stewart2010-05-161-232/+72
| | | | | | | | | | | | | | am now able to run 32 cores ok.. but I still will hang on buildworld with a NFS problem. I suspect I am missing a patch for the netlogic rge driver. JC check and see if I am missing anything except your core-mask changes Obtained from: JC Notes: svn path=/head/; revision=208165
* If a mbuf is split across two pages, weRandall Stewart2010-02-101-0/+2
| | | | | | | | | | | | | | | | have code that detects this and makes two transmit descriptors. However its possible that the algorithm detects when the second page is not used (when the data aligns perfectly to the bottom of the page). This caused a 0 len descriptor to be added which locks up the rge device. Skip such things with a continue. JC provided this patch... Thanks JC :-) Obtained from: JC (c.jayachandran@gmail.com) Notes: svn path=/head/; revision=203754
* 1) Make sure static is init'd to 0Randall Stewart2010-01-261-1/+3
| | | | | | | | 2) In one place make sure we call the backup startup routine (from the timer). Notes: svn path=/head/; revision=203010
* Correct a path in an include I missed earlierWarner Losh2010-01-111-8/+1
| | | | | | | Remove references to if_watchdog. The rge_watchdog routine was empty anyway. Notes: svn path=/head/; revision=202092
* Attempt to cope with the dev/rmi -> mips/rmi/dev move.Warner Losh2010-01-111-5/+7
| | | | Notes: svn path=/head/; revision=202066
* Merge from projects/mips to head by hand:Warner Losh2010-01-101-0/+2748
Copy sys/dev/rmi to sys/mips/rmi/dev [sic]. For devices that are on only one SoC, or family of SoC, we place them under sys/<vendor>/dev. I'll fix the build problems this causes as best I can since rmi kernel require external toolchains due to lack of support for rmi op-codes in the ancient binutils we have in the tree. Notes: svn path=/head/; revision=201979