From owner-freebsd-bugs@freebsd.org Fri May 29 06:29:02 2020 Return-Path: Delivered-To: freebsd-bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0EF3A330E32 for ; Fri, 29 May 2020 06:29:02 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 49YF5T6hYfz488n for ; Fri, 29 May 2020 06:29:01 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id E3A38330E31; Fri, 29 May 2020 06:29:01 +0000 (UTC) Delivered-To: bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E250F330F2C for ; Fri, 29 May 2020 06:29:01 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49YF5T5Y49z484M for ; Fri, 29 May 2020 06:29:01 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B9C0C12D6A for ; Fri, 29 May 2020 06:29:01 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 04T6T1Vs040443 for ; Fri, 29 May 2020 06:29:01 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 04T6T1Df040419 for bugs@FreeBSD.org; Fri, 29 May 2020 06:29:01 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 204521] [new driver] [request] Port rtsx from OpenBSD to FreeBSD Date: Fri, 29 May 2020 06:28:57 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: feature, patch X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: zeus.panchenko@gmail.com X-Bugzilla-Status: In Progress X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 May 2020 06:29:02 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D204521 --- Comment #129 from Zeus Panchenko --- when an empty microSD adaptor inserted first and the very microSD card inse= rted after that, I see CRC errors kldunload/load doesn't help, only reboot > uname FreeBSD 12.1-RELEASE-p3 GENERIC amd64 > git log commit d02fc0ebfc0983cc1ed9e00657b2316fda1c36fe here dmesg output for these actions: 1. module unload/load 2. insert/remove microSD adaptor with card 3. insert an empty microSD adaptor 4. insert a card into the microSD adaptor full dmesg uploaded here: https://pastebin.com/JVGvPKxm > dmesg rtsx0: detached pci2: at device 0.0 (no driver attached) rtsx0: mem 0xc1200000-0xc1200fff at device 0.0 on pci2 rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x2010000 rtsx0: Card inserted/removed rtsx0: No request running rtsx0: Card inserted mmc0: on rtsx0 rtsx0: rtsx_mmcbr_acquire_host() rtsx0: Read ivar #9, value 0 / #0 rtsx0: Write ivar #7, value 0x1 / #1 rtsx0: Read ivar #6, value 0x3c0000 / #3932160 rtsx0: Write ivar #11, value 0x15 / #21 rtsx0: Write ivar #0, value 0x1 / #1 rtsx0: Write ivar #2, value 0 / #0 rtsx0: Write ivar #1, value 0 / #0 rtsx0: Write ivar #9, value 0x1 / #1 rtsx0: Write ivar #3, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_bus_power_up() rtsx0: Write ivar #12, value 0x2 / #2 rtsx0: rtsx_mmcbr_switch_vccq(330) rtsx0: Write ivar #3, value 0x61a80 / #400000 rtsx0: Write ivar #14, value 0 / #0 rtsx0: Write ivar #9, value 0x2 / #2 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_set_sd_clock(400000) rtsx0: Write ivar #0, value 0x2 / #2 mmc0: Probing bus rtsx0: Write ivar #2, value 0x1 / #1 rtsx0: rtsx_mmcbr_update_ios() mmc0: REQUEST: CMD0 arg 0 flags 0x40 rtsx0: rtsx_mmcbr_request(CMD0 arg 0 flags 0x40 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 mmc0: CMD0 RESULT: 0 rtsx0: Write ivar #2, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() mmc0: REQUEST: CMD8 arg 0x1aa flags 0x75 rtsx0: rtsx_mmcbr_request(CMD8 arg 0x1aa flags 0x75 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0x00000868 0x0000aa01 0x7dabff00 0x7dacff01 0x7dadffaa rtsx0: cmd->resp =3D 0x000001aa 0x00000000 0x00000000 0x00000000 mmc0: CMD8 RESULT: 0 mmc0: SD 2.0 interface conditions: OK mmc0: REQUEST: CMD55 arg 0 flags 0x15 rtsx0: rtsx_mmcbr_request(CMD55 arg 0 flags 0x15 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0x00003768 0x00002001 0x7dabff00 0x7dacff00 0x7dadff00 rtsx0: cmd->resp =3D 0x00000120 0x00000000 0x00000000 0x00000000 mmc0: CMD55 RESULT: 0 mmc0: REQUEST: CMD41 arg 0 flags 0x61 rtsx0: rtsx_mmcbr_request(CMD41 arg 0 flags 0x61 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0xff003f68 0x00000080 0x7dabff00 0x7dacff00 0x7dadff00 rtsx0: cmd->resp =3D 0x00ff8000 0x00000000 0x00000000 0x00000000 mmc0: CMD41 RESULT: 0 mmc0: SD probe: OK (OCR: 0x00ff8000) rtsx0: Write ivar #8, value 0xff8000 / #16744448 rtsx0: Read ivar #8, value 0xff8000 / #16744448 rtsx0: Write ivar #2, value 0x1 / #1 rtsx0: rtsx_mmcbr_update_ios() mmc0: REQUEST: CMD0 arg 0 flags 0x40 rtsx0: rtsx_mmcbr_request(CMD0 arg 0 flags 0x40 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 mmc0: CMD0 RESULT: 0 rtsx0: Write ivar #2, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() rtsx0: Read ivar #8, value 0xff8000 / #16744448 mmc0: Current OCR: 0x00ff8000 rtsx0: Read ivar #8, value 0xff8000 / #16744448 rtsx0: Read ivar #7, value 0x1 / #1 mmc0: REQUEST: CMD8 arg 0x1aa flags 0x75 rtsx0: rtsx_mmcbr_request(CMD8 arg 0x1aa flags 0x75 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() ... mmc0: CMD41 RESULT: 0 mmc0: REQUEST: CMD55 arg 0 flags 0x15 rtsx0: rtsx_mmcbr_request(CMD55 arg 0 flags 0x15 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0x00003768 0x00002001 0x7dabff00 0x7dacff00 0x7dadff00 rtsx0: cmd->resp =3D 0x00000120 0x00000000 0x00000000 0x00000000 mmc0: CMD55 RESULT: 0 mmc0: REQUEST: CMD41 arg 0x40ff8000 flags 0x61 rtsx0: rtsx_mmcbr_request(CMD41 arg 0x40ff8000 flags 0x61 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0xff003f68 0x00000080 0x7dabffff 0x7dacff80 0x7dadff00 rtsx0: cmd->resp =3D 0x00ff8000 0x00000000 0x00000000 0x00000000 mmc0: CMD41 RESULT: 0 mmc0: REQUEST: CMD55 arg 0 flags 0x15 rtsx0: rtsx_mmcbr_request(CMD55 arg 0 flags 0x15 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 rtsx0: cmd_buffer: 0x00003768 0x00002001 0x7dabff00 0x7dacff00 0x7dadff00 rtsx0: cmd->resp =3D 0x00000120 0x00000000 0x00000000 0x00000000 mmc0: CMD55 RESULT: 0 ... rtsx0: Interrupt handler - enabled: 0x32000000, status: 0xa0090000 mmc0: CMD7 RESULT: 0 rtsx0: rtsx_mmcbr_release_host() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x2000000 rtsx0: Card inserted/removed rtsx0: No request running rtsx0: Card removed rtsx0: Write ivar #0, value 0x1 / #1 rtsx0: Write ivar #2, value 0 / #0 rtsx0: Write ivar #1, value 0 / #0 rtsx0: Write ivar #9, value 0 / #0 rtsx0: Write ivar #3, value 0 / #0 rtsx0: Write ivar #14, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_set_sd_clock(0) rtsx0: rtsx_bus_power_off() mmc0: detached rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x2010000 rtsx0: Card inserted/removed rtsx0: No request running rtsx0: Card inserted mmc0: on rtsx0 rtsx0: rtsx_mmcbr_acquire_host() rtsx0: Read ivar #9, value 0 / #0 rtsx0: Write ivar #7, value 0x1 / #1 rtsx0: Read ivar #6, value 0x3c0000 / #3932160 rtsx0: Write ivar #11, value 0x15 / #21 rtsx0: Write ivar #0, value 0x1 / #1 rtsx0: Write ivar #2, value 0 / #0 rtsx0: Write ivar #1, value 0 / #0 rtsx0: Write ivar #9, value 0x1 / #1 rtsx0: Write ivar #3, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_bus_power_up() rtsx0: Write ivar #12, value 0x2 / #2 rtsx0: rtsx_mmcbr_switch_vccq(330) rtsx0: Write ivar #3, value 0x61a80 / #400000 rtsx0: Write ivar #14, value 0 / #0 rtsx0: Write ivar #9, value 0x2 / #2 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_set_sd_clock(400000) rtsx0: Write ivar #0, value 0x2 / #2 mmc0: Probing bus rtsx0: Write ivar #2, value 0x1 / #1 rtsx0: rtsx_mmcbr_update_ios() mmc0: REQUEST: CMD0 arg 0 flags 0x40 rtsx0: rtsx_mmcbr_request(CMD0 arg 0 flags 0x40 dlen 0 dflags 0) rtsx0: rtsx_send_cmd() ... rtsx0: CRC error rtsx0: Soft reset mmc0: CMD17 RESULT: 2 rtsx0: rtsx_mmcbr_release_host() rtsx0: rtsx_mmcbr_acquire_host() mmc0: REQUEST: CMD17 arg 0x10 flags 0x35 data 512 rtsx0: rtsx_mmcbr_request(CMD17 arg 0x10 flags 0x35 dlen 512 dflags 0x2) rtsx0: rtsx_xfer_short() - Read xfer: 512 bytes with block size 512 rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x90090080 rtsx0: CRC error rtsx0: Soft reset mmc0: CMD17 RESULT: 2 rtsx0: rtsx_mmcbr_release_host() rtsx0: rtsx_mmcbr_acquire_host() mmc0: REQUEST: CMD17 arg 0x80 flags 0x35 data 512 rtsx0: rtsx_mmcbr_request(CMD17 arg 0x80 flags 0x35 dlen 512 dflags 0x2) rtsx0: rtsx_xfer_short() - Read xfer: 512 bytes with block size 512 rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x90090080 rtsx0: CRC error rtsx0: Soft reset mmc0: CMD17 RESULT: 2 rtsx0: rtsx_mmcbr_release_host() rtsx0: rtsx_mmcbr_acquire_host() mmc0: REQUEST: CMD17 arg 0 flags 0x35 data 512 rtsx0: rtsx_mmcbr_request(CMD17 arg 0 flags 0x35 dlen 512 dflags 0x2) rtsx0: rtsx_xfer_short() - Read xfer: 512 bytes with block size 512 rtsx0: rtsx_send_cmd() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x90090080 rtsx0: CRC error rtsx0: Soft reset mmc0: CMD17 RESULT: 2 rtsx0: rtsx_mmcbr_release_host() rtsx0: Interrupt handler - enabled: 0x32000000, status: 0x2000000 rtsx0: Card inserted/removed rtsx0: No request running rtsx0: Card removed mmc0: Card at relative address 7 deleted rtsx0: Write ivar #0, value 0x1 / #1 rtsx0: Write ivar #2, value 0 / #0 rtsx0: Write ivar #1, value 0 / #0 rtsx0: Write ivar #9, value 0 / #0 rtsx0: Write ivar #3, value 0 / #0 rtsx0: Write ivar #14, value 0 / #0 rtsx0: rtsx_mmcbr_update_ios() rtsx0: rtsx_set_sd_clock(0) rtsx0: rtsx_bus_power_off() mmc0: detached --=20 You are receiving this mail because: You are the assignee for the bug.=