Giter Club home page Giter Club logo

rtsx's Introduction

A port of OpenBSD rtsx driver to FreeBSD

Based on https://www.freebsd.org/doc/en_US.ISO8859-1/books/arch-handbook/pci.html example,

and https://lists.freebsd.org/pipermail/freebsd-hackers/2018-April/052520.html


HOWTO COMPILE AND INSTALL:

Place source in /usr/src/sys/dev/rtsx

make clean
make
make install

HOWTO RUN:

kldload mmc
kldload mmcsd
kldload rtsx

For debugging:

dev.rtsx.0.debug_mask can be set with the following masks:

  • 0x01 - to show the basic flow of the driver,

  • 0x02 - to trace the SD commands,

  • 0x04 - to trace the tuning phase.

HISTORY:

  • probe of Vendor ID: 0x10ec - Device ID: 0x5287
  • attach (and dev initialization...)
  • detect card inserted / ejected
  • get card information
  • detach (at least kldunload)
  • patch to add detection of SD card insertion/removal (from Gary Jennejohn [email protected])
  • patch to read SCR and STATUS (CMD51 & CMD13) (from Jesper Schmitz Mouridsen [email protected])
  • patch to allow successful read operations (from Jesper Schmitz Mouridsen [email protected])
  • write operation completed with Jesper Schmitz Mouridsen [email protected].
  • patch for RTS525A from Lutz Bichler [email protected]
  • add read-only detection
  • add suspend and resume (at least on Acer Aspire E 15 E5-576-77W6)
  • committed to head (FreeBSD 13.0-CURRENT) by revision 367998.

TODO:

  • More testing please!

TESTED ON:

  • RTS5209 under releng/13.0 (Lenovo ThinkPad L520, Packard Bell EN LV44HC i3-2328M)
  • RTS5227 under stable/11, releng/12.1 and releng/13.0 releng/13.1 (HP ProBook 430 g2, HP Elitebook 820 G2, Lenovo ThinkPad S440/T450/T450s/X240/X250/X270/yoga 1, Fujitsu H730)
  • RTS5229 under releng/12.1 and releng/13.0 (Lenovo IdeaPad 120S-14IAP, ASUS GL553VE)
  • RTS522A under releng/12.1 and releng/13.0 (Intel NUC8i5BE, ThinkPad P50s, ThinkPad T470p, Thinkpad x260, HP EliteBook 840 G3)
  • RTS525A under releng/12.1 (Dell Latitude E5570, Dell XPS 13 - model 9360)
  • RTL8411B under stable/12 and releng/13.0 (Acer Aspire E 15 E5-576-77W6, ACER ASPIRE 5 A515-51G-C97B)
  • RTS5260 under 14.0-CURRENT (Dell XPS 13 9310)

KNOWN BUGS:

  • RTS522A on Lenovo P50s and Lenovo T470p, card detection and read-only switch are reversed. To adapt the driver add in loader.conf(5) dev.rtsx.0.inversion=1.
  • Mounting a filesystem with write access on a card write protected may involve a kernel crash.
  • Suspend/Resume do not work under MMCCAM.
  • For some chips (e.g. RTS5260) after devctl disable/enable or kldunload/kldload the driver can't detect a card correctly.

NOTE:

rtsx's People

Contributors

hlh-restart avatar mizhka avatar ruupert avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

rtsx's Issues

RTS5129 - Lenovo IdeaPad 510-15IKB 80SV - FreeBSD 12.2

Good evening,

I downloaded the source code from ports, at https://www.freshports.org/sysutils/rtsx-kmod/, used make install clean, restarted the machine but it seems that something is wrong, couldn't even see any device added to /dev...

Here's the probe of my laptop https://bsd-hardware.info/?probe=3ebe1fd064

I even added the driver on kld_list for loading at boot time but no success.

What may I'm missing?

I want to help testing, ๐Ÿ™‚

Thank you.

Fix missing opt_cam.h for MCCCAM on 12.1 and add DEBUG_FLAGS

Computer description

Lenovo ideapad 120S-14IAP

Hardware description

rtsx0@pci0:1:0:0:       class=0xff0000 card=0x522910ec chip=0x522910ec rev=0x01 hdr=0x00
    vendor     = 'Realtek Semiconductor Co., Ltd.'
    device     = 'RTS5229 PCI Express Card Reader'
    bar   [10] = type Memory, range 32, base 0x91200000, size 4096, enabled
dev.rtsx.0.cam_status: 1
dev.rtsx.0.write_count: 0
dev.rtsx.0.read_count: 35
dev.rtsx.0.debug: 0
dev.rtsx.0.force_timing: 0
dev.rtsx.0.inversion: 0
dev.rtsx.0.read_only: 0
dev.rtsx.0.req_timeout: 10
dev.rtsx.0.%parent: pci1
dev.rtsx.0.%pnpinfo: vendor=0x10ec device=0x5229 subvendor=0x10ec subdevice=0x5229 class=0xff0000
dev.rtsx.0.%location: slot=0 function=0 dbsf=pci0:1:0:0 handle=\_SB_.PCI0.RP01.PXSX
dev.rtsx.0.%driver: rtsx
dev.rtsx.0.%desc: 2.0a Realtek RTS5229 PCI MMC/SD Card Reader
dev.rtsx.%parent: 

FreeBSD version

12.1-RELEASE-p1 FreeBSD  with options MMCCAM

opt_cam.h not found
fix:

--- a/Makefile
+++ b/Makefile
@@ -3,11 +3,12 @@
 .if RTSX_INVERSION
 CFLAGS+= -DRTSX_INVERSION
 .endif
+KMOD=  rtsx
+SRCS=  rtsx.c
+SRCS+= device_if.h bus_if.h pci_if.h mmcbr_if.h 
 .if RTSX_CAM
 CFLAGS+= -DMMCCAM
+SRCS+=opt_cam.h
 .endif
-KMOD=  rtsx
-SRCS=  rtsx.c
-SRCS+= device_if.h bus_if.h pci_if.h mmcbr_if.h
-
+DEBUG_FLAGS=-g
 .include <bsd.kmod.mk>
sudo camcontrol devlist
<RTITF128PCA1MADL SAFR12.6>        at scbus1 target 0 lun 0 (pass0,ada0)
<SDHC SL16G 8.0 SN 6BEF484F MFG 04/2017 >  at scbus3 target 0 lun 0 (sdda0,pass1)

freebsd 13.1 issues on THINKPAD x250

Computer description

THINKPAD X250

Hardware description

The output of 
` pciconf -lvb rtsx0 `
`rtsx0@pci0:2:0:0:	class=0xff0000 rev=0x01 hdr=0x00 vendor=0x10ec device=0x5227 subvendor=0x17aa subdevice=0x2226
    vendor     = 'Realtek Semiconductor Co., Ltd.'
    device     = 'RTS5227 PCI Express Card Reader'
    bar   [10] = type Memory, range 32, base 0xf1100000, size 4096, enabled`
and
` sysctl dev.rtsx 
dev.rtsx.0.write_count: 0
dev.rtsx.0.read_count: 92
dev.rtsx.0.debug_mask: 0
dev.rtsx.0.force_timing: 0
dev.rtsx.0.inversion: 0
dev.rtsx.0.read_only: 1
dev.rtsx.0.timeout_cmd: 1
dev.rtsx.0.timeout_io: 10
dev.rtsx.0.%parent: pci1
dev.rtsx.0.%pnpinfo: vendor=0x10ec device=0x5227 subvendor=0x17aa subdevice=0x2226 class=0xff0000
dev.rtsx.0.%location: slot=0 function=0 dbsf=pci0:2:0:0
dev.rtsx.0.%driver: rtsx
dev.rtsx.0.%desc: 2.1d Realtek RTS5227 PCIe MMC/SD Card Reader
dev.rtsx.%parent: `

FreeBSD version
13.1 BETA1

The output of ` uname -a `
`FreeBSD x250 13.1-BETA1 FreeBSD 13.1-BETA1 #0 releng/13.1-n249974-ad329796bdb: Thu Mar 10 02:30:25 UTC 2022     [email protected]:/usr/obj/usr/src/amd64.amd64/sys/GENERIC amd64`

Describe the bug

Trying to mount SDCARD fails and after sleep it comes very slow and gives timeout error

Console messages

The output of `dmesg | egrep "rtsx0|mmc0|mmcsd0" `
`rtsx0: <2.1d Realtek RTS5227 PCIe MMC/SD Card Reader> mem 0xf1100000-0xf1100fff at device 0.0 on pci1
rtsx0: Interrupt card inserted/removed
rtsx0: Card present
rtsx0: A card is detected
mmc0: <MMC/SD bus> on rtsx0
mmcsd0: 62GB <SDHC SD64G 6.0 SN DA7B8E1C MFG 06/2019 by 39 PH> (read-only) at mmc0 50.0MHz/4bit/2048-block
rtsx0: Suspend
rtsx0: Resume
rtsx0: Controller timeout for CMD0
rtsx0: Controller timeout for CMD0
rtsx0: Controller timeout for CMD0
rtsx0: Controller timeout for CMD0
rtsx0: Controller timeout for CMD8
rtsx0: Controller timeout for CMD8
rtsx0: Controller timeout for CMD8
rtsx0: Controller timeout for CMD8
rtsx0: Controller timeout for CMD55
rtsx0: Controller timeout for CMD55
rtsx0: Controller timeout for CMD55
rtsx0: Controller timeout for CMD55
rtsx0: Controller timeout for CMD1
rtsx0: Controller timeout for CMD1
rtsx0: Controller timeout for CMD1
rtsx0: Controller timeout for CMD1
mmc0: No compatible cards found on bus`

now after lsblk it is not visible any more

 lsblk
DEVICE         MAJ:MIN SIZE TYPE                                          LABEL MOUNT
ada0             0:93  447G GPT                                               - -
  <FREE>         -:-   1.0M -                                                 - -
  ada0p1         0:96  100M efi                                         gpt/EFI /boot/efi
  ada0p2         0:97   16M ms-reserved        gpt/Microsoft%20reserved%20partition -
  ada0p3         0:98  300G ms-basic-data          gpt/Basic%20data%20partition -
  ada0p4         0:99  509M ms-recovery                                       - -
  ada0p5         0:100  39G freebsd-ufs                                       - /
  ada0p6         0:101 8.0G freebsd-swap                                      - SWAP
  ada0p7         0:102 8.0G linux-swap                                        - -
  ada0p8         0:103  92G linux-data                                        - -

can you please help me with this
thank

Non-critical issue regarding some console spam

Hello,
I'm one of the early backers of the rtsx porting bountysource effort, and my thanks to you are vast.
Just one little thing that is more of a generally insignificant 'cosmetic' issue, is a line of innocuous noise/spam to the console.
During boot, when an SD Card is not present in the slot, we observe:
rtsx0: pci_read_config() error - reg: 0xeeffffaa ---which appears to be just an announcement that there's no card present.
The device is otherwise perfectly functional & performs as intended.
Is there any way to suppress this message to the console?

In case it matters, this occurs on a Dell XPS 9380 running FreeBSD 13.0-RELEASE & 13-STABLE & 14-CURRENT.
rtsx0@pci0:1:0:0: class=0xff0000 rev=0x01 hdr=0x00 vendor=0x10ec device=0x525a subvendor=0x1028 subdevice=0x08af
vendor = 'Realtek Semiconductor Co., Ltd.'
device = 'RTS525A PCI Express Card Reader'

RTS522A on a Lenovo P50s

[email protected] encounter a card detection problem on his Lenovo P50s.

  • A card is detected as present when no card is inserted,
  • A card is detected as absent when a card is inserted.

Compilation fails on recent CURRENT

cc  -O2 -pipe -fno-strict-aliasing  -Werror -D_KERNEL -DKLD_MODULE -nostdinc   -include /wrkdirs/usr/ports/sysutils/rtsx-kmod/work/rtsx-1.0g/opt_global.h -I. -I/usr/src/sys -I/usr/src/sys/contrib/ck/include -fno-common  -fdebug-prefix-map=./machine=/usr/src/sys/i386/include -fdebug-prefix-map=./x86=/usr/src/sys/x86/include     -MD  -MF.depend.rtsx.o -MTrtsx.o -mno-mmx -mno-sse -msoft-float -ffreestanding -fwrapv -fstack-protector -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wcast-qual -Wundef -Wno-pointer-sign -D__printf__=__freebsd_kprintf__ -Wmissing-include-dirs -fdiagnostics-show-option -Wno-unknown-pragmas -Wno-error-tautological-compare -Wno-error-empty-body -Wno-error-parentheses-equality -Wno-error-unused-function -Wno-error-pointer-sign -Wno-error-shift-negative-value -Wno-address-of-packed-member -Wno-format-zero-length   -mno-aes -mno-avx  -std=iso9899:1999 -c rtsx.c -o rtsx.o
rtsx.c:634:12: error: format specifies type 'long' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Werror,-Wformat]
                                              rtsx_read_count, rtsx_write_count);
                                              ^~~~~~~~~~~~~~~
rtsx.c:634:29: error: format specifies type 'long' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Werror,-Wformat]
                                              rtsx_read_count, rtsx_write_count);
                                                               ^~~~~~~~~~~~~~~~
2 errors generated.
*** [rtsx.o] Error code 1

Full build log: http://beefy17.nyi.freebsd.org/data/head-i386-default/p545799_s364495/logs/rtsx-1.0.g,1.log

Issues with RTS5229 on Intel NUC7i5BN

Computer description

Intel NUC - NUC7i5BN

Hardware description

rtsx0@pci0:58:0:0:	class=0xff0000 card=0x20688086 chip=0x522910ec rev=0x01 hdr=0x00
    vendor     = 'Realtek Semiconductor Co., Ltd.'
    device     = 'RTS5229 PCI Express Card Reader'
    bar   [10] = type Memory, range 32, base 0xde100000, size 4096, enabled

FreeBSD version

FreeBSD r2d2 12.1-RELEASE-p3 FreeBSD 12.1-RELEASE-p3 GENERIC  amd64

Describe the bug

I was able to get it to detect at first but couldn't mount the card, I tried removing / inserting a couple times and get this in /var/log/messages:

 tail -f /var/log/messages
Jun  7 18:53:58 r2d2 kernel: mmc0: ACMD41 failed, RESULT: 4
Jun  7 18:54:00 r2d2 kernel: rtsx0: Interrupt card inserted/removed
Jun  7 18:54:00 r2d2 kernel: rtsx0: Controller timeout
Jun  7 18:54:00 r2d2 kernel: rtsx0: Soft reset
Jun  7 18:54:02 r2d2 kernel: rtsx0: Controller timeout
Jun  7 18:54:02 r2d2 kernel: rtsx0: Soft reset
Jun  7 18:54:04 r2d2 kernel: rtsx0: Controller timeout
Jun  7 18:54:04 r2d2 kernel: rtsx0: Soft reset
Jun  7 18:54:06 r2d2 kernel: rtsx0: Controller timeout
Jun  7 18:54:06 r2d2 kernel: rtsx0: Soft reset
Jun  7 18:54:38 r2d2 kernel: rtsx0: Interrupt card inserted/removed
Jun  7 18:54:38 r2d2 kernel: rtsx0: No request running
Jun  7 18:54:38 r2d2 kernel: mmc0: detached



Jun  7 18:54:43 r2d2 kernel: rtsx0: Interrupt card inserted/removed
Jun  7 18:54:43 r2d2 kernel: rtsx0: No request running
Jun  7 18:54:43 r2d2 kernel: mmc0: <MMC/SD bus> on rtsx0
Jun  7 18:54:43 r2d2 kernel: mmcsd0: 16GB <SDHC SA16G 4.9 SN 4814F0D2 MFG 06/2019 by 2 TM> at mmc0 50.0MHz/4bit/256-block

Last attempt seems to work and I see the device in gpart show:

=>      63  30277569  mmcsd0  MBR  (14G)
        63      8129          - free -  (4.0M)
      8192  30269440       1  fat32lba  (14G)

mounting waits for a while until I get a i/o error

mount /dev/mmcsd0 /mnt
load: 0.20  cmd: mount 3093 [g_waitidle] 24.69r 0.00u 0.00s 0% 2300k
load: 0.20  cmd: mount 3093 [g_waitidle] 24.96r 0.00u 0.00s 0% 2300k
load: 0.20  cmd: mount 3093 [g_waitidle] 25.13r 0.00u 0.00s 0% 2300k
mount: /dev/mmcsd0: Input/output error

Console messages

(Note that there's a few remove/insert attempts:

dmesg | egrep "rtsx0|mmc0|mmcsd0"
rtsx0: <Realtek RTS5229 PCI MMC/SD Card Reader> mem 0xde100000-0xde100fff at device 0.0 on pci1
rtsx0: Interrupt card inserted/removed
rtsx0: No request running
mmc0: <MMC/SD bus> on rtsx0
rtsx0: Interrupt card inserted/removed
rtsx0: Interrupt card inserted/removed
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Interrupt card inserted/removed
rtsx0: Controller timeout
rtsx0: Soft reset
mmc0: ACMD41 failed, RESULT: 4
rtsx0: Interrupt card inserted/removed
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Controller timeout
rtsx0: Soft reset
rtsx0: Interrupt card inserted/removed
rtsx0: No request running
mmc0: detached
rtsx0: Interrupt card inserted/removed
rtsx0: No request running
mmc0: <MMC/SD bus> on rtsx0
mmcsd0: 16GB <SDHC SA16G 4.9 SN 4814F0D2 MFG 06/2019 by 2 TM> at mmc0 50.0MHz/4bit/256-block
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
g_vfs_done():mmcsd0[READ(offset=65536, length=8192)]error = 5
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout

The build fails for i386 CURRENT

From packages building cluster log:

cc  -O2 -pipe -fno-strict-aliasing  -Werror -D_KERNEL -DKLD_MODULE -nostdinc   -include /wrkdirs/usr/ports/sysutils/rtsx-kmod/work/rtsx-2020-06-11/opt_global.h -I. -I/usr/src/sys -I/usr/src/sys/contrib/ck/include -fno-common  -fdebug-prefix-map=./machine=/usr/src/sys/i386/include -fdebug-prefix-map=./x86=/usr/src/sys/x86/include     -MD  -MF.depend.rtsx.o -MTrtsx.o -mno-mmx -mno-sse -msoft-float -ffreestanding -fwrapv -fstack-protector -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wcast-qual -Wundef -Wno-pointer-sign -D__printf__=__freebsd_kprintf__ -Wmissing-include-dirs -fdiagnostics-show-option -Wno-unknown-pragmas -Wno-error-tautological-compare -Wno-error-empty-body -Wno-error-parentheses-equality -Wno-error-unused-function -Wno-error-pointer-sign -Wno-error-shift-negative-value -Wno-address-of-packed-member -Wno-format-zero-length   -mno-aes -mno-avx  -std=iso9899:1999 -c rtsx.c -o rtsx.o
rtsx.c:1475:10: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len, cmd->data->xfer_len);
                              ^~~~~~~~~~~~~~
rtsx.c:1475:26: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len, cmd->data->xfer_len);
                                              ^~~~~~~~~~~~~~~~~~~
rtsx.c:1479:10: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len);
                              ^~~~~~~~~~~~~~
rtsx.c:1669:10: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len, cmd->data->xfer_len);
                              ^~~~~~~~~~~~~~
rtsx.c:1669:26: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len, cmd->data->xfer_len);
                                              ^~~~~~~~~~~~~~~~~~~
rtsx.c:1673:10: error: format specifies type 'long' but the argument has type 'size_t' (aka 'unsigned int') [-Werror,-Wformat]
                              cmd->data->len, RTSX_DMA_DATA_BUFSIZE);
                              ^~~~~~~~~~~~~~
6 errors generated.

Full log: http://beefy17.nyi.freebsd.org/data/head-i386-default/p538633_s362138/logs/rtsx-2020.06.11.log

Minor bit of spam to console

EXCELLENT WORK!!!!!
I'm one of the funders at the Bounty Source post for a driver for FreeBSD. Although I ended up hardly ever using the card reader, I did consider it to be the only thing to be "amiss" with my laptop. I find myself using the card reader for all sorts of unnecessary tasks now, just because I'm happy to use it finally.

The Specs:
Dell XPS 13 - model 9360 (Dell internal ID 0T3FTF)
FreeBSD nomad 12.1-STABLE FreeBSD 12.1-STABLE r361728 corvenus amd64 1201517

pciconf -lv:
rtsx0@pci0:59:0:0: class=0xff0000 card=0x075b1028 chip=0x525a10ec rev=0x01 hdr=0x00
vendor = 'Realtek Semiconductor Co., Ltd.'
device = 'RTS525A PCI Express Card Reader'

I've attached some images for overview.
The only minor insignificant "nag" is some spam to the console. It does not appear to cause any functional issues, and I am not even sure why it occurs. In any case, the console spam occurs with / without a card inserted and with / without data on the card. Perhaps it is just some quirk that is unique to my brand/model hardware.
For some glossy imagery:
Screenshot_2020-06-02_14-30-24
Screenshot_2020-06-02_14-32-01
Screenshot_2020-06-03_17-50-51

Again, thank you very much for your efforts & this should definitely make it into the FreeBSD ecosystem soon enough!

fstyp /dev/mmcsd0 fails

Computer description

ASUS GL553VE

Hardware description

rtsx0@pci0:4:0:0:       class=0xff0000 rev=0x01 hdr=0x00 vendor=0x10ec device=0x5229 subvendor=0x1043 subdevice=0x202f
    vendor     = 'Realtek Semiconductor Co., Ltd.'
    device     = 'RTS5229 PCI Express Card Reader'
    bar   [10] = type Memory, range 32, base 0xdf100000, size 4096, enabled

FreeBSD version

FreeBSD sbreeze 13.0-CURRENT FreeBSD 13.0-CURRENT #22 r360432: Thu Apr 30 02:24:19 +04 2020     root@sbreeze:/usr/obj/usr/src/amd64.amd64/sys/AMENITY  amd64

Describe the bug

Running fstyp /dev/mmcsd0 results in:

fstyp: fread: Operation not supported
fstyp: fread: Operation not supported
fstyp: fread: Operation not supported
fstyp: fread: Operation not supported
fstyp: fread: Operation not supported

Console messages

rtsx0: <Realtek RTS5229 PCI MMC/SD Card Reader> mem 0xdf100000-0xdf100fff at device 0.0 on pci4
rtsx0: pci_read_config() error
rtsx0: Card absent
rtsx0: Interrupt card inserted/removed
rtsx0: Card present
rtsx0: Interrupt card inserted/removed
rtsx0: Card absent
rtsx0: Interrupt card inserted/removed
rtsx0: Card present
mmc0: <MMC/SD bus> on rtsx0
mmcsd0: 4GB <SDHC SA04G 1.1 SN 221D2C36 MFG 12/2013 by 2 TM> at mmc0 50.0MHz/4bit/256-block
rtsx0: Controller timeout for CMD17
rtsx0: Soft reset
rtsx0: Interrupt card inserted/removed
rtsx0: Card present
mmc0: <MMC/SD bus> on rtsx0
mmcsd0: 4GB <SDHC SA04G 1.1 SN 221D2C36 MFG 12/2013 by 2 TM> at mmc0 50.0MHz/4bit/256-block
rtsx0: Spurious interrupt
rtsx0: Controller timeout for CMD17
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD17
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD17
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD17
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD18
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD18
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout
rtsx0: Controller timeout for CMD18
rtsx0: Soft reset
mmcsd0: Error indicated: 1 Timeout

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.