Re: [BUG/REGRESSION] Kernel 4.5-rc1 on Acube Sam460ex AMCC 460ex Power PC motherboards

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jan 25, 2016 at 4:46 AM, Julian Margetson <runaway@xxxxxxxx> wrote:
> Oops starting Xorg with kernel 4.5-rc1 on Acube Sam460ex amcc460ex powerpc
> motherboard.
>
> ======================================================================================================================
> 01c8f1c44b83a0825b573e7c723b033cece37b86 is the first bad commit
> commit 01c8f1c44b83a0825b573e7c723b033cece37b86
> Author: Dan Williams <dan.j.williams@xxxxxxxxx>
> Date:   Fri Jan 15 16:56:40 2016 -0800
>
>     mm, dax, gpu: convert vm_insert_mixed to pfn_t
>
>     Convert the raw unsigned long 'pfn' argument to pfn_t for the purpose of
>     evaluating the PFN_MAP and PFN_DEV flags.  When both are set it triggers
>     _PAGE_DEVMAP to be set in the resulting pte.
>
>     There are no functional changes to the gpu drivers as a result of this
>     conversion.
>
>     Signed-off-by: Dan Williams <dan.j.williams@xxxxxxxxx>
>     Cc: Dave Hansen <dave@xxxxxxxx>
>     Cc: David Airlie <airlied@xxxxxxxx>
>     Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
>     Signed-off-by: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>
>
> :040000 040000 dc71b6dc188dea4b6ce95f5fd1e4e73cc3663cbe
> 8a745459a14cd2a6f4e1c71fda3e54333d023f43 M arch
> :040000 040000 9e8103b65698f677e17becdac53914ca029a6197
> f656e15bffef4ea8c848176a79eb50a071ec323e M drivers
> :040000 040000 3ffc222d7e0f1067772798d08777aeb54136026e
> e2b423f85aaaf0cb25d48d1e15771fc5bddf7981 M fs
> :040000 040000 392d2dea8185ba8f0d1c101782831ceed9aa9812
> 9e3001b04052daa1b3204b6f2a6e26138a4ed7dd M include
> :040000 040000 f81d8cfe3052b7259b75a58656a65efdaad40284
> 969d0ff262020f27a695172ce89ae5f6088e8d44 M mm
>

Hmm, this commit could only cause a behavior change if it modifies the
value of the pfn as seen by insert_pfn().  Can you try the attached
debug patch to see if that assumption is being violated?
diff --git a/include/linux/pfn_t.h b/include/linux/pfn_t.h
index 37448ab5fb5c..81813051cec7 100644
--- a/include/linux/pfn_t.h
+++ b/include/linux/pfn_t.h
@@ -16,10 +16,25 @@
 #define PFN_DEV (1UL << (BITS_PER_LONG - 3))
 #define PFN_MAP (1UL << (BITS_PER_LONG - 4))
 
+extern pfn_t phys_to_pfn_t(phys_addr_t addr, unsigned long flags);
+
+static inline bool pfn_t_has_page(pfn_t pfn)
+{
+	return (pfn.val & PFN_MAP) == PFN_MAP || (pfn.val & PFN_DEV) == 0;
+}
+
+static inline unsigned long pfn_t_to_pfn(pfn_t pfn)
+{
+	return pfn.val & ~PFN_FLAGS_MASK;
+}
+
 static inline pfn_t __pfn_to_pfn_t(unsigned long pfn, unsigned long flags)
 {
 	pfn_t pfn_t = { .val = pfn | (flags & PFN_FLAGS_MASK), };
 
+	WARN_ONCE(pfn_t_to_pfn(pfn_t) != pfn, "pfn: %#lx pfn_t: %#lx\n",
+			pfn, pfn_t_to_pfn(pfn_t));
+
 	return pfn_t;
 }
 
@@ -29,18 +44,6 @@ static inline pfn_t pfn_to_pfn_t(unsigned long pfn)
 	return __pfn_to_pfn_t(pfn, 0);
 }
 
-extern pfn_t phys_to_pfn_t(phys_addr_t addr, unsigned long flags);
-
-static inline bool pfn_t_has_page(pfn_t pfn)
-{
-	return (pfn.val & PFN_MAP) == PFN_MAP || (pfn.val & PFN_DEV) == 0;
-}
-
-static inline unsigned long pfn_t_to_pfn(pfn_t pfn)
-{
-	return pfn.val & ~PFN_FLAGS_MASK;
-}
-
 static inline struct page *pfn_t_to_page(pfn_t pfn)
 {
 	if (pfn_t_has_page(pfn))
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel

[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux