From owner-freebsd-amd64@freebsd.org Wed Aug 3 00:03:52 2016 Return-Path: Delivered-To: freebsd-amd64@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 452B8BAD88A for ; Wed, 3 Aug 2016 00:03:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1A7A11BDD for ; Wed, 3 Aug 2016 00:03:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id u7303prH032318 for ; Wed, 3 Aug 2016 00:03:51 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-amd64@FreeBSD.org Subject: [Bug 209924] 11.0 -r301815 buildkernel via amd64-gcc fails for: .../dev/drm2/i915/dvo_ch7xxx.c related redundant declarations Date: Wed, 03 Aug 2016 00:03:52 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.0-BETA3 X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: commit-hook@freebsd.org X-Bugzilla-Status: In Progress X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: ngie@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-Mailman-Approved-At: Wed, 03 Aug 2016 00:14:05 +0000 X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Aug 2016 00:03:52 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D209924 --- Comment #9 from commit-hook@freebsd.org --- A commit references this bug: Author: ngie Date: Wed Aug 3 00:03:03 UTC 2016 New revision: 303689 URL: https://svnweb.freebsd.org/changeset/base/303689 Log: MFC r302571,r302572,r302577,r302841: Approved by: re (gjb) r302571: Remove redundant declaration for radeon_pm_acpi_event_handler(..) to fix -Wredundant-decls warning PR: 209924 Tested with: devel/amd64-gcc (5.3.0) r302572: Remove redundant declarations for intel_fbc_enabled(..) and i915_gem_dump_object(..) to fix -Wredundant-decls warning PR: 209924 Tested with: devel/amd64-gcc (5.3.0) r302577: Add missing default case to capable(..) function definition By definition (enum __drm_capabilities), cases other than CAP_SYS_ADMIN aren't possible. Add in a KASSERT safety belt and return false in !INVARIANTS case if an invalid value is passed in, as it would be a programmer error. This fixes a -Wreturn-type error with gcc 5.3.0. r302841: Always panic if an invalid capability is passed to `capable(..)` instead = of just with INVARIANTS rwatson's point was valid in the sense that if the data passed at runtime= is invalid, it should always trip the invariant, not just in the debug case. This is a deterrent against malicious input, or input caused by hardware errors. Requested by: rwatson Changes: _U stable/11/ stable/11/sys/dev/drm2/drm_os_freebsd.h stable/11/sys/dev/drm2/i915/i915_drv.h stable/11/sys/dev/drm2/radeon/radeon_acpi.c --=20 You are receiving this mail because: You are on the CC list for the bug.=