From owner-freebsd-arm@freebsd.org Sat Jun 11 12:56:11 2016 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A9372AEE868 for ; Sat, 11 Jun 2016 12:56:11 +0000 (UTC) (envelope-from guyyur@gmail.com) Received: from mail-wm0-x229.google.com (mail-wm0-x229.google.com [IPv6:2a00:1450:400c:c09::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46F3C2D33; Sat, 11 Jun 2016 12:56:11 +0000 (UTC) (envelope-from guyyur@gmail.com) Received: by mail-wm0-x229.google.com with SMTP id r190so7350482wmr.0; Sat, 11 Jun 2016 05:56:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to; bh=OBwcubtRX1yV1/l9WFfAI1y/kvYhV4JBX26gAPvA9mA=; b=oJiD+pOZaUcVCsTYyRVWgGtm2cAPE9vmETRcnqBnqhofdF5O0Yxr+CBq3Gx4XINy9S SiC0CkdD0o23yWQfCTaou7/vQTgvcCDAb1WY7Nu7KhQogisD/lKjIITvL7bSidPV0rj8 uoxcjW1pbxj+jKh1qpkf1UbisR0G/Ap1C/WiNLOExTS+MECs6Xi0lm7TNTHPfPOZssWj +f3t4Q7f4UiDf6tcCZwv/jENFTzK5CzdIKF/rl7anEQ5MjYjMpjr5nuKZ/T2uoSzF59l aoXB5sfvxZkOWIzVBMVBapueBKtZBcFOw4SQIczY8JiJEkMNh48kSx+wWvcGh3oY+YL3 tPvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=OBwcubtRX1yV1/l9WFfAI1y/kvYhV4JBX26gAPvA9mA=; b=VdjqdccQc7WpeiyoMxjHuBxUdUHjAnZrP0m/QoSqe0E9czJBfDCR8DaN++BLVEBjy9 J8UNT7p0dlmMty2FgH7oAJn5dixxkGPPrsOS/9/Kz0FWFDcpVLIRD3M1RKcH84Di1cEy 8TT/+hWMRJsvlCpQlsMhx3VQLg1LDlXRlDnVPsRPuV7mxjDtzI0GPp9w4CJXmf9GhVaH VucrMZ114B1geQmlbBh4aB5cWNXaeARFQM/TcFRR91oeBI4spSMfuVq58/lKpPKFpOf8 KT/Z+AMyUjbul3WmlgQDGuptGAPsa0F2pbr2Ao0oGVhV7VcY3HDGI3O1eJzgpYa33ukM cR+Q== X-Gm-Message-State: ALyK8tJkAwR9iwtyKAzIDYkmpH5Bj5mH3sjeREljBq9bI+/lZS6aBxtdKHVaE0YPyZjWL5PBg11cQSyX5yphIg== X-Received: by 10.194.76.33 with SMTP id h1mr6400624wjw.43.1465649769650; Sat, 11 Jun 2016 05:56:09 -0700 (PDT) MIME-Version: 1.0 Received: by 10.28.9.142 with HTTP; Sat, 11 Jun 2016 05:56:09 -0700 (PDT) From: Guy Yur Date: Sat, 11 Jun 2016 15:56:09 +0300 Message-ID: Subject: ODROID C1+ doesn't finish booting on 11-CURRENT after r301062 To: freebsd-arm , andrew@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Jun 2016 12:56:11 -0000 Hi, My ODROID C1+ gets stuck during boot starting with r301062 (still gets stuck with r301778). Sometimes there are continuous prints of "mmcsd0: Error indicated: 1 Timeout". When there are no mmcsd timeouts, it still doesn't get to the login prompt with last print being the NIC bringup. Adding the bellow print code to gic_bind() mask loop, I see arm_gic_map[cpu] is 0 when setting one of the IRQs. for (mask = 0, cpu = 0; cpu < end; cpu++) if (CPU_ISSET(cpu, cpus)) { mask |= arm_gic_map[cpu]; if (arm_gic_map[cpu] != 1 << cpu) device_printf(sc->gic_dev, "irq = %u, cpu = %u, arm_gic_map[cpu] = 0x%08x\n", irq, cpu, arm_gic_map[cpu]); } # dmesg | grep -B1 arm_gic_map Release APs gic0: irq = 32, cpu = 1, arm_gic_map[cpu] = 0x00000000 # dmesg | grep -B1 arm_gic_map Release APs gic0: irq = 35, cpu = 2, arm_gic_map[cpu] = 0x00000000 If I add prints to the end of gic_bind() the board boots fine. (Probably because of the delay added by the prints) Example: device_printf(sc->gic_dev, "irq = %u, mask = 0x%08x\n", irq, mask); return (0); # dmesg | grep -e "gic0: pn" -e "gic0: irq" -e "Release APs" gic0: pn 0x390, arch 0x1, rev 0x1, implementer 0x43b irqs 256 gic0: irq = 32, mask = 0x00000001 gic0: irq = 42, mask = 0x00000001 gic0: irq = 122, mask = 0x00000001 gic0: irq = 58, mask = 0x00000001 gic0: irq = 107, mask = 0x00000001 gic0: irq = 125, mask = 0x00000001 gic0: irq = 60, mask = 0x00000001 gic0: irq = 110, mask = 0x00000001 gic0: irq = 62, mask = 0x00000001 gic0: irq = 63, mask = 0x00000001 gic0: irq = 40, mask = 0x00000001 gic0: irq = 35, mask = 0x00000001 Release APs gic0: irq = 32, mask = 0x00000002 gic0: irq = 35, mask = 0x00000004 gic0: irq = 40, mask = 0x00000008 gic0: irq = 42, mask = 0x00000001 gic0: irq = 58, mask = 0x00000002 gic0: irq = 60, mask = 0x00000004 gic0: irq = 62, mask = 0x00000008 gic0: irq = 63, mask = 0x00000001 gic0: irq = 107, mask = 0x00000002 gic0: irq = 110, mask = 0x00000004 gic0: irq = 122, mask = 0x00000008 gic0: irq = 125, mask = 0x00000001 Thanks, Guy