summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2019-08-27kernel: prohibit changing cache attributes (SG_CACHED|SG_DEVICE) in ↵cinap_lenrek
segattach(), set SG_RONLY in data2txt() the user should not be able to change the cache attributes for a segment in segattach() as this can cause the same memory to be mapped with conflicting attributes in the cache. SG_TEXT should always be mapped with SG_RONLY attribute. so fix data2txt() to follow the rules.
2019-08-27kernel: make user stack segment non-executablecinap_lenrek
2019-08-27pc64: implement NX bit discovery, map kernel mappings no-executecinap_lenrek
2019-08-27kernel: catch execution read fault on SG_NOEXEC segment (for mips)cinap_lenrek
2019-08-27kernel: catch execution read fault on SG_NOEXEC segmentcinap_lenrek
fault() now has an additional pc argument that is used to detect fault on a non-executable segment. that is, we check on read fault if the segment has the SG_NOEXEC attribute and the program counter is within faulting page.
2019-08-26kernel: expose no execute bit to portable mmu code as SG_NOEXEC / PTENOEXEC, ↵cinap_lenrek
add PTECACHED bits a portable SG_NOEXEC segment attribute was added to allow non-executable (physical) segments. which will set the PTENOEXEC bits for putmmu(). in the future, this can be used to make non-executable stack / bss segments. the SG_DEVICE attribute was added to distinguish between mmio regions and uncached memory. only matterns on arm64. on arm, theres the issue that PTEUNCACHED would have no bits set when using the hardware bit definitions. this is the reason bcm, kw, teg2 and omap kernels use arteficial PTE constants. on zynq, the XN bit was used as a hack to give PTEUNCACHED a non-zero value and when the bit is clear then cache attributes where added to the pte. to fix this, PTECACHED constant was added. the portable mmu code in fault.c will now explicitely set PTECACHED bits for cached memory and PTEUNCACHED for uncached memory. that way the hardware bit definitions can be used everywhere.
2019-08-26vncv: fix snarf buffer realloc memory corruptionqwx
fix never updating p when snarf is reallocated, resulting in memory corruption.
2019-08-25emmc: 50MHz highspeed support (from richard miller)cinap_lenrek
2019-08-25bcm64: replace emmc2 driver with richard millers sdhc drivercinap_lenrek
the new driver supports 50MHz highspeed bus mode and uses ADMA instead of SDMA.
2019-08-24/sys/lib/dist/mkfile: adjust 2GB for pi3 and zynq imgcinap_lenrek
2019-08-24/sys/lib/dist/mkfile: storage vendors idea of 2GB is deflatingcinap_lenrek
2019-08-23bcm64: deal with discontinuous memory regions, avoid virtual memory ↵cinap_lenrek
aliasing, implement vmap() proper on the 2GB and 4GB raspberry pi 4 variants, there are two memory regions for ram: [0x00000000..0x3e600000) [0x40000000..0xfc000000) the framebuffer is somewhere at the end of the first GB of memory. to handle these, we append the region base and limit of the second region to *maxmem= like: *maxmem=0x3e600000 0x40000000 0xfc000000 the mmu code has been changed to have non-existing ram unmapped and mmukmap() now uses small 64K pages instead of 512GB pages to avoid aliasing (framebuffer). the VIRTPCI mapping has been removed as we now have a proper vmap() implementation which assigns vritual addresses automatically.
2019-08-22bcm: invalidate cache on Fbinfo after firmware completioncinap_lenrek
2019-08-22bcm: flush out early boot messages on uart and screen initializationcinap_lenrek
make early boot messages available by writing out kmesg.buf after uart and screen initialization.
2019-08-21/sys/lib/acid/kernel: fix procstk() for arm64, set kdir for arm/arm64 to ↵cinap_lenrek
bcm/bcm64
2019-08-21bcm: set XN bits for kernel device mappingscinap_lenrek
2019-08-19bcm64: do not use OTP_BOOTMODE_REG to determine OSC frequency (thanks ↵cinap_lenrek
richard miller) the register does not seem to be accessible on the Rpi 3b. so instead hardcode oscfreq in the Soc structure.
2019-08-19disk/format: implement long name supportcinap_lenrek
2019-08-18add missing device tree file for raspberry pi 4cinap_lenrek
2019-08-18add raspberry pi 4 kernel and bootloader to pi3.img targetcinap_lenrek
2019-08-18bcm64: add support for more than 1GB of ram (untested)cinap_lenrek
this adds a 4GB KMAP window into the kernel address space so we can access all physical ram on raspberry pi 4 for user pages. note that kernel memory above KZERO is still limited to 1GB because of DMA restrictions.
2019-08-18bcm64: add driver for emmc2 controllercinap_lenrek
2019-08-16bcm: fix typo in gpio.c on unused AFedge0 constantcinap_lenrek
2019-08-16bcm64: poll gisb arbiter for asynchronous bus errorscinap_lenrek
2019-08-16ethergenet: remove debuggingcinap_lenrek
the hangs where caused by missing NX bits on the mmio mappings, so the debug code is not needed anymore.
2019-08-16bcm64: set XN bits for kernel device mappingscinap_lenrek
2019-08-12cc: use 7 octal digits for 21 bit runescinap_lenrek
2019-08-02libauth: do not set errstr in auth_rpc() for ARdone result (thanks majiru)cinap_lenrek
2019-07-28bcm, bcm64: add vcore support for raspberry pi 3 GPIO expandercinap_lenrek
2019-07-27bcm, bcm64: add BCM2711 support for gpiopull(), fix gpiomeminit(), cleanupcinap_lenrek
according to the following linux change, BCM2711 uses a different method for changing pullup/down mode: https://github.com/raspberrypi/linux/commit/abcfd092860760087b87acbdda0963fe7906839c#diff-cf078559c38543ac72c5db99323e236d gpiomeminit() was broken, using virtual address for the gpio physseg instead of the physical one. cleanup the code, avoid repetition by declaring static u32int *regs variable. make local variable names consistent.
2019-07-27bcm64: fix wrong prescaler for generic timer on rpi4cinap_lenrek
the raspberry pi 4 uses 54 instead of 19.2 MHz crystal. detect which frequency is used by reading OTP bootmode register: https://www.raspberrypi.org/documentation/hardware/raspberrypi/otpbits.md Bit 1: sets the oscillator frequency to 19.2MHz
2019-07-25ethergenet: fix flow control negotiationcinap_lenrek
2019-07-25bcm, bcm64: clean dma destination buffer before issuing dma in case of non ↵cinap_lenrek
cache-line-size aligned buffer
2019-07-25bcm64: add config for raspberry pi 4cinap_lenrek
2019-07-25bcm64: work in progress genet ethernet driver for raspberry pi 4cinap_lenrek
2019-07-25bcm64: reorganize virtual memory map for rapberry pi4cinap_lenrek
2019-07-25bcm64: update io.h for pci express and raspberry pi 4cinap_lenrek
2019-07-25bcm64: add pci express driver for raspberry pi 4cinap_lenrek
2019-07-25bcm64: add gic interrupt controller driver for raspberry pi 4cinap_lenrek
2019-07-25bcm64: add gisb arbiter driver to catch bus timeoutscinap_lenrek
2019-07-25bcm, bcm64: make irq.$O optional and add intrdisable(), use intrenable()cinap_lenrek
the raspberry pi 4 has a new interrupt controller and pci support, so get rid of intrenable() macro and properly make intrenable function with tbdf argument.
2019-07-25bcm64: strip debug symbols to make sure .img file is multiple of 4 bytescinap_lenrek
the raspberry pi4 firmware refuses to enable the GIC interrup controller for arm64 when the .img file is not a multiple of 4 bytes. yes, this is insane and nowhere documented.
2019-07-25bcm, bcm64: add dmaflush() function and make virtio size and virtual address ↵cinap_lenrek
configurable in Soc.virtio and Soc.iosize
2019-07-25bcm, bcm64: add support for device tree parameter passingcinap_lenrek
the new raspberry pi 4 firmware for arm64 seems to have broken atag support. so we now parse the device tree structure to get the bootargs and memory configuration.
2019-07-17usbxhci: implement portable dma flush operations and move to port/cinap_lenrek
2019-07-17usbehci: introduce dmaflush() function to handle portable cache invalidation ↵cinap_lenrek
for device drivers
2019-07-11mergecinap_lenrek
2019-07-11kernel: move common ethermii to port/cinap_lenrek
2019-07-11devuart: make sure uart is enabled in uartkick()cinap_lenrek
2019-07-02walk(1): add history sectionAlex Musolino