From owner-freebsd-current@freebsd.org Mon Oct 21 01:16:39 2019 Return-Path: Delivered-To: freebsd-current@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 2637B16FC1E for ; Mon, 21 Oct 2019 01:16:39 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from wout4-smtp.messagingengine.com (wout4-smtp.messagingengine.com [64.147.123.20]) (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 46xJd15Xvjz4Z8D for ; Mon, 21 Oct 2019 01:16:37 +0000 (UTC) (envelope-from yuripv@yuripv.net) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.west.internal (Postfix) with ESMTP id 309483B1 for ; Sun, 20 Oct 2019 21:16:35 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Sun, 20 Oct 2019 21:16:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yuripv.net; h= subject:to:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm1; bh=Y +JqqWOFnP8+EMXd3ZZFOCyQLN+++nnF/31X5vqTM8c=; b=Zv7noYolOcXnOhBaH EbWxiDB0OHrcmP8nmW6/grnag0MrQBUPYahySzk4sBcqpRt34P5azajCLHfQKU85 TKw/GGOUAluk18RIRh0pfoFbEQ2bRoHcKafhQ4XgYruJP+GNeXD/jYDtgq+mbEVf 9RKeq73M3Uu1Amcp8NjtlTgoYGYUo2YlSWFvK1bPgjSxWRnaJ1wY0aMXC1DBpXHZ i2kdukkeIb76TzrK2ru5xkG65kbBKAKSnk5pL/YS+kgGAMkRczhpjd90d0OJXRs5 tfq76QIE/KoaESeDoi3rjU5tzBTnV+vh8nRHi7CsFSnSnQ9w4X94qX4Z0WhvOLYE Z7WGg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=Y+JqqWOFnP8+EMXd3ZZFOCyQLN+++nnF/31X5vqTM 8c=; b=U+XrP4/2QgnVVIwp8JegwvOh/P8KkvnVjQVjV46I1uI8iF1YsJut2E/6g 3bbhJkoouk1w84kcEwVLLs8RsWqGuc3s1nI4rHoWEwFP/foAoq92dt4iDhSDH4ED sbUn0jaMyAxWEG8fTMEp+S5EysMWu5voeJOwOBsuRpygZhC2kF60t2ODrOQqOib1 FuiQhWrfauB67znUcR8bWqb5oWRQj5lMeN3cHOnTRxZIEPVUVChNJck7aOU2+/iu HFgiGu/py+/jfum31CUE5x9XhOcbS7A4dSUqHzMtJkaicqnV1v47ryzl7tSOfdXh iW4TOu8e4EZ9mAa5yYyU6FmW6FG3g== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedufedrkeeggdegfecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhepuffvfhfhkffffgggjggtgfesthekre dttdefjeenucfhrhhomhepjghurhhiucfrrghnkhhovhcuoeihuhhrihhpvheshihurhhi phhvrdhnvghtqeenucffohhmrghinhepfhhrvggvsghsugdrohhrghenucfkphepvdduje drudegiedrkedvrdduudelnecurfgrrhgrmhepmhgrihhlfhhrohhmpeihuhhrihhpvhes hihurhhiphhvrdhnvghtnecuvehluhhsthgvrhfuihiivgeptd X-ME-Proxy: Received: from [192.168.1.10] (unknown [217.146.82.119]) by mail.messagingengine.com (Postfix) with ESMTPA id 289D2D60057 for ; Sun, 20 Oct 2019 21:16:34 -0400 (EDT) Subject: Re: DRM-current-kmod is still a problem at r353339 To: freebsd-current@freebsd.org References: <7ca3b30a-81f6-f79d-1486-7fd29765646f@acm.org> <99c89ca0-462c-f4c7-fa07-6f61e9d39d66@acm.org> <3bb2e410-51dd-bc3f-7660-41a4683551b3@daemonic.se> <20191017195347.GB6447@raichu> <53ff1ac5-c7e8-1b6c-bd43-481eaef61120@daemonic.se> <72d67f0a-aeef-1c06-2b12-9351a1f52060@anduin.net> <689d53378dcca22adb29aa23f03e8e1b@neelc.org> <25593555-6452-0933-d0fe-0459425cde55@delphij.net> <7cb6ecd6-2dcd-92e4-75a3-5e5d34377ed6@yuripv.net> From: Yuri Pankov Message-ID: <7409427c-0934-8aa9-7bea-8820c32f97a4@yuripv.net> Date: Mon, 21 Oct 2019 04:16:32 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.1.2 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 46xJd15Xvjz4Z8D X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=yuripv.net header.s=fm1 header.b=Zv7noYol; dkim=pass header.d=messagingengine.com header.s=fm1 header.b=U+XrP4/2; dmarc=none; spf=pass (mx1.freebsd.org: domain of yuripv@yuripv.net designates 64.147.123.20 as permitted sender) smtp.mailfrom=yuripv@yuripv.net X-Spamd-Result: default: False [-6.08 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[yuripv.net:s=fm1,messagingengine.com:s=fm1]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:64.147.123.20]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-current@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_COUNT_THREE(0.00)[4]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[yuripv.net:+,messagingengine.com:+]; DMARC_NA(0.00)[yuripv.net]; IP_SCORE(-3.48)[ip: (-9.76), ipnet: 64.147.123.0/24(-4.91), asn: 11403(-2.68), country: US(-0.05)]; RCVD_IN_DNSWL_LOW(-0.10)[20.123.147.64.list.dnswl.org : 127.0.5.1]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:11403, ipnet:64.147.123.0/24, country:US]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Oct 2019 01:16:39 -0000 On 10/21/2019 4:14 AM, Neel Chauhan wrote: > For me, the following code is still necessary for me (HP Spectre x360 > 2018), which is the remaining parts of the patches not committed if you > are using a recent kernel. I don't know about you all ThinkPad users, it > should still apply as it's Intel in general not just HP or Lenovo. > Without these patches, I get a kernel panic. > > Keep in mind that the patch may render as spaces, but it should be tabs. > > Index: amd64/pmap.c > =================================================================== > --- amd64/pmap.c    (revision 353788) > +++ amd64/pmap.c    (working copy) > @@ -355,8 +355,9 @@ >      }                        \ >  } while (0) > > -#define    CHANGE_PV_LIST_LOCK_TO_VM_PAGE(lockp, m)    \ > -            CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, VM_PAGE_TO_PHYS(m)) > +#define    CHANGE_PV_LIST_LOCK_TO_VM_PAGE(lockp, m) do {    \ > +        CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, VM_PAGE_TO_PHYS(m)); \ > +} while (0) > >  #define    RELEASE_PV_LIST_LOCK(lockp)        do {    \ >      struct rwlock **_lockp = (lockp);        \ > @@ -951,8 +952,16 @@ >  static u_long * >  pmap_delayed_invl_genp(vm_page_t m) >  { > +    vm_paddr_t pa; > +    u_long *gen; > > -    return (&pa_to_pmdp(VM_PAGE_TO_PHYS(m))->pv_invl_gen); > +    pa = VM_PAGE_TO_PHYS(m); > +    if (__predict_false((pa) > pmap_last_pa)) > +        gen = &pv_dummy_large.pv_invl_gen; > +    else > +        gen = &(pa_to_pmdp(pa)->pv_invl_gen); > + > +    return (gen); >  } >  #else >  static u_long * If you look below, that's exactly the patch mjg@ provided and Xin pointed you at. > On 2019-10-20 02:45, Yuri Pankov wrote: >> On 10/18/2019 8:01 AM, Xin Li wrote: >>> Another (semi-fixed!) data point -- I can confirm that with if >>> (vm_page_sleep_if_busy(page, "linuxkpi")) >>>   -> if (!vm_page_busy_acquire(page, VM_ALLOC_WAITFAIL)) change and >>> mjg@'s earlier patch at >>> https://people.freebsd.org/~mjg/pmap-fict-invl.diff (please commit it) , >>> the latest drm-v5.0 branch of drm-current-kmod worked just fine with >>> Intel HD Graphics P630 on Lenovo P51. >> >> Confirmed that it worked for me too on P51. >> >> Sorry for offtopic, but do you see the console getting "stuck" after >> loading i915kms, i.e. for input to show you need to switch to another >> console and back?