]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - share/man/man4/altera_sdcard.4
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / share / man / man4 / altera_sdcard.4
1 .\"-
2 .\" Copyright (c) 2012 Robert N. M. Watson
3 .\" All rights reserved.
4 .\"
5 .\" This software was developed by SRI International and the University of
6 .\" Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237)
7 .\" ("CTSRD"), as part of the DARPA CRASH research programme.
8 .\"
9 .\" Redistribution and use in source and binary forms, with or without
10 .\" modification, are permitted provided that the following conditions
11 .\" are met:
12 .\" 1. Redistributions of source code must retain the above copyright
13 .\"    notice, this list of conditions and the following disclaimer.
14 .\" 2. Redistributions in binary form must reproduce the above copyright
15 .\"    notice, this list of conditions and the following disclaimer in the
16 .\"    documentation and/or other materials provided with the distribution.
17 .\"
18 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
19 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
22 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 .\" SUCH DAMAGE.
29 .\"
30 .\" $FreeBSD$
31 .\"
32 .Dd August 18, 2012
33 .Dt ALTERA_SDCARD 4
34 .Os
35 .Sh NAME
36 .Nm altera_sdcard
37 .Nd driver for the Altera University Program Secure Data Card IP Core
38 .Sh SYNOPSIS
39 .Cd "device altera_sdcard"
40 .Pp
41 In
42 .Pa /boot/device.hints :
43 .Cd hint.altera_sdcardc.0.at="nexus0"
44 .Cd hint.altera_sdcardc.0.maddr=0x7f008000
45 .Cd hint.altera_sdcardc.0.msize=0x400
46 .Sh DESCRIPTION
47 The
48 .Nm
49 device driver provides support for the Altera University Program Secure Data
50 Card (SD Card) IP Core device.
51 A controller device,
52 .Li altera_sdcardcX ,
53 will be attached during boot.
54 Inserted disks are presented as
55 .Xr disk 9
56 devices,
57 .Li altera_sdcardX ,
58 corresponding to the controller number.
59 .Sh HARDWARE
60 The current version of the
61 .Nm
62 driver supports the SD Card IP core as described in the August 2011 version of
63 Altera's documentation.
64 The core supports only cards up to 2G (CSD 0); larger cards, or cards using
65 newer CSD versions, will not be detected.
66 The IP core has two key limitations: a lack of interrupt support, requiring
67 timer-driven polling to detect I/O completion, and support for only single
68 512-byte block read and write operations at a time.
69 The combined effect of those two limits is that the system clock rate,
70 .Dv HZ ,
71 must be set to at least 200 in order to accomplish the maximum 100KB/s data
72 rate supported by the IP core.
73 .Sh SEE ALSO
74 .Xr disk 9
75 .Rs
76 .%T Altera University Program Secure Data Card IP Core
77 .%D August 2011
78 .%I Altera Corporation - University Program
79 .%U ftp://ftp.altera.com/up/pub/Altera_Material/11.0/University_Program_IP_Cores/Memory/SD_Card_Interface_for_SoPC_Builder.pdf
80 .Re
81 .Sh HISTORY
82 The
83 .Nm
84 device driver first appeared in
85 .Fx 10.0 .
86 .Sh AUTHORS
87 The
88 .Nm
89 device driver and this manual page were
90 developed by SRI International and the University of Cambridge Computer
91 Laboratory under DARPA/AFRL contract
92 .Pq FA8750-10-C-0237
93 .Pq Do CTSRD Dc ,
94 as part of the DARPA CRASH research programme.
95 This device driver was written by
96 .An Robert N. M. Watson .
97 .Sh BUGS
98 .Nm
99 contains a number of work-arounds for IP core bugs.
100 Perhaps most critically,
101 .Nm
102 ignores the CRC error bit returned in the RR1 register, which appears to be
103 unexpectedly set by the IP core.
104 .Pp
105 .Nm
106 uses fixed polling intervals are used for card insertion/removal and
107 I/O completion detection; an adaptive strategy might improve performance by
108 reducing the latency to detecting completed I/O.
109 However, in our experiments, using polling rates greater than 200 times a
110 second did not improve performance.
111 .Pp
112 .Nm
113 supports only a
114 .Li nexus
115 bus attachment, which is appropriate for system-on-chip busses such as
116 Altera's Avalon bus.
117 If the IP core is configured off of another bus type, then additional bus
118 attachments will be required.