Commit Graph

236909 Commits

Author SHA1 Message Date
jmcneill
8fc8e58857 don't select SDR12 mode if we are <= 400 kHz 2015-08-03 00:44:52 +00:00
jmcneill
a9d443eb60 dont confuse signaling voltage and bus voltage 2015-08-03 00:19:27 +00:00
jmcneill
8b09343dd9 Add support for eMMC 5.0 HS200 timings. 2015-08-02 22:47:05 +00:00
jmcneill
57b5f3f4ec enable UHS support 2015-08-02 22:09:43 +00:00
jmcneill
8055da5b7d let SDHC_FLAG_HOSTCAPS override SDHC_CAPABILITIES2 as well 2015-08-02 22:01:28 +00:00
jmcneill
778d004ee1 set ref clk to 204MHz so we can take advantage of UHS-I modes 2015-08-02 21:45:52 +00:00
jmcneill
30f521ffbf add support for UHS-I modes on capable 3.0+ controllers 2015-08-02 21:45:12 +00:00
jmcneill
d0524104f2 Add basic UHS-I support. SDR50 and SDR104 are supported, but not DDR50. 2015-08-02 21:44:36 +00:00
jmcneill
cb960d1469 add makefile for installing hdmicecio.h 2015-08-02 21:22:34 +00:00
dholland
d36f790b9a whoops, fix 32-bit build 2015-08-02 20:23:21 +00:00
dholland
a296d73dae Pass the fs object to LFS_MAX_DADDR so it can check lfs_is64.
Remove some hackish intentional 64->32 truncations next to the checks
using LFS_MAX_DADDR, and tackle the problem they handled in bmap
instead.

The problem: the magic block pointer value UNWRITTEN has magic value
-2, and if it's not handled specifically, uint32 -> uint64 promotion
turns it into 4294967294, which then causes consternation and
monkeyhouse downstream.

What's here is still kind of a hack, but it's a step forward.
2015-08-02 18:18:46 +00:00
dholland
9e5184b86b Add a (draft) 64-bit superblock. Make things build again.
Add pieces of support for using both superblock types where
convenient, and specifically to the superblock accessors, but don't
actually enable it anywhere.

First substantive step on PR 50000.
2015-08-02 18:18:09 +00:00
dholland
992b9a23af Use accessor functions for the version field of the lfs superblock.
I thought at first maybe the cases that test the version should be
rolled into the accessors, but on the whole I think the conclusion on
that is no.
2015-08-02 18:14:16 +00:00
dholland
1d22bb8bfe lfs_cleanint[] in the in-memory superblock needs to have 64-bit entries. 2015-08-02 18:12:59 +00:00
dholland
f5b8b21a8e Make i_eff_nblks in the in-memory inode 64 bits wide. 2015-08-02 18:12:41 +00:00
dholland
31c72b56c0 Don't include ufs headers. 2015-08-02 18:12:18 +00:00
dholland
9263edc766 Use the lfs header file and lfs's mount args struct, not ufsmount.h
and the ffs mount args struct, for mounting lfs.

(they are the same, so this doesn't matter yet, but still...)
2015-08-02 18:11:57 +00:00
dholland
ae8b3536ce Typo in comment. 2015-08-02 18:11:36 +00:00
dholland
eed9c32288 Use c99 initializers. 2015-08-02 18:11:12 +00:00
dholland
baa6681581 Fix catastrophic bug in lfs_rewind() that changed segment numbers
(lfs_curseg/lfs_nextseg in the superblock) using the wrong units.
These fields are for whatever reason the start addresses of segments
(measured in frags) rather than the segment numbers 0..n.

This only apparently affects dumping from a mounted fs; however, it
trashes the fs.

I would really, really like to have a static analysis tool that can
keep track of the units things are measured in, since fs code is full
of conversion macros and the macros are named inscrutable things like
"sntod" whose letters don't necessarily even correspond to the units
they convert. It is surprising that more of these are not wrong.
2015-08-02 18:10:55 +00:00
dholland
078ffcb8d8 Second batch of 64 -> 32 truncations in lfs, along with more minor
tidyups and corrections in passing.
2015-08-02 18:10:07 +00:00
dholland
95a8d28c27 Fix assorted 64 -> 32 truncations in lfs. Also, some minor tidyups and
corrections in passing.
2015-08-02 18:08:12 +00:00
dholland
e12e41530f Allow superblock accessors that widen 32-bit disk fields to 64-bit
memory values.
2015-08-02 17:57:27 +00:00
dholland
af0d133055 Fix bug: for format version 1, the superblock "size" field is measured
in blocks instead of frags, so use lfs_blkstofrags to correct it.

This code was instead multiplying by the block size divided by
DEV_BSIZE to get the number of disk blocks rather than the number of
frags. (I gather that originally these were the same, but they're not
necessarily any more.)
2015-08-02 17:56:24 +00:00
jmcneill
df3fcab6a5 When halting a channel, abort the current DMA CB and reset the channel
before stopping DMA.
2015-08-02 16:46:12 +00:00
wiz
282efd00b8 Fix two typos. 2015-08-02 12:19:12 +00:00
mlelstv
0f0a1013e5 count collisions, count and debug print more errors. 2015-08-02 11:55:28 +00:00
mlelstv
6297339c02 use dk_openlock when accessing openmask. 2015-08-02 11:40:41 +00:00
jmcneill
bf94bade59 bus_dma_segment_t ds_addr is bus_addr_t not paddr_t (another case of it) 2015-08-02 11:28:01 +00:00
jmcneill
c753669c8d bus_dma_segment_t ds_addr is bus_addr_t not paddr_t 2015-08-02 11:26:21 +00:00
jmcneill
f9279be4bd install jetsontk1 boot script as boot.scr 2015-08-02 11:11:32 +00:00
jmcneill
799ebb3ae1 Install hdmicecio.h 2015-08-02 11:09:05 +00:00
maxv
9cd6cd69f5 Wrong logic. Here, userland can control the size and the data copied, which
basically means it can overflow kernel memory.

ok martin@ christos@
2015-08-02 07:37:57 +00:00
mlelstv
5ad98aacf2 fix diskerr message, it needs the driver name, not the device unit name. 2015-08-02 07:25:40 +00:00
mlelstv
b296682ed1 Be more verbose about error conditions. 2015-08-02 07:14:10 +00:00
mlelstv
f89cb33206 correct (the commented out) calculation of bus frequency. 2015-08-02 07:07:02 +00:00
manu
3a71cbe970 Do not VFS_SYNC before VFS_UNMOUNT on force unmount
VFS_SYNC does not consider whether we are performing a force unmount or not,
and therefore it can wait for a while if the filesytstem is misbehaving.
Removing VFS_SYNC before VFS_UNMOUNT on forced unmount fixes the problem.

This should not cause harm as the VFS_SYNC seems just useless.
As noted by Chuck Silvers in
http://mail-index.netbsd.org/tech-kern/2015/07/13/msg019156.html
- Nothing seems to prevent vnodes from getting dirty again after VFS_SYNC call.
- Filesystems do flush data through vflush() in VFS_UNMOUNT anyway.

As a consequence, the VFS_SYNC call in do_unmount() could probably be
completely removed. But since such a change is quite dangerous, we just
remove it in the case of forced unmounts, which are situations where
the risk of data loss is known to the operator.
2015-08-02 03:29:22 +00:00
christos
429d474275 remove reference to SCCS which is not supported anymore.
XXX: pullup-7
2015-08-02 03:19:02 +00:00
jmcneill
bfaf326c74 enable eMMC 2015-08-02 00:24:45 +00:00
jmcneill
4c59c4959f return MMC_OCR_HCS bit from host_ocr if the controller supports high-speed mode 2015-08-02 00:24:24 +00:00
jmcneill
57d12b8828 add hdmicec 2015-08-01 21:30:09 +00:00
jmcneill
ded9bc704e Enable tegracec and hdmicec 2015-08-01 21:20:46 +00:00
jmcneill
ab82ac0e7d Add driver for Tegra HDMI CEC controller. 2015-08-01 21:20:11 +00:00
jmcneill
72fc9317eb Add an API for HDMI CEC devices. HDMI Consumer Electronics Control (CEC) is
a protocol that provides high-level control functions between CEC-capable
connected devices.
2015-08-01 21:19:24 +00:00
skrll
9c4bc51ae1 Re-enable cpus [123] now that bcm2835_intr.c is fixed with rev 1.11/ 2015-08-01 16:18:47 +00:00
skrll
5be1b5ad5a Call the correct ipi handlers for IPI_AST and IPI_KPREEMPT 2015-08-01 14:18:00 +00:00
tsutsui
bd35314409 Pull upstream fix to avoid kernel panic on starting X on Intel 855GM machines.
Reported in PR kern/49875, and ok'ed to commit by riastradh@.

Should be pulled up to netbsd-7.
2015-08-01 13:42:32 +00:00
jmcneill
c33ccff2e1 use a larger (64KB) block size, this helps SD card performance 2015-08-01 10:05:51 +00:00
jmcneill
54fb23f641 mount root partition with noatime 2015-08-01 10:04:50 +00:00
jmcneill
e3283cc16e Align partitions to 64MB for the benefit of SD cards > 32GB 2015-08-01 10:04:06 +00:00