Patch "MIPS: vpe-mt: drop physical_memsize" has been added to the 4.14-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    MIPS: vpe-mt: drop physical_memsize

to the 4.14-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     mips-vpe-mt-drop-physical_memsize.patch
and it can be found in the queue-4.14 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 85cb0e7be9a2118139f351478f51d90df3d22d27
Author: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
Date:   Sun Feb 19 15:15:25 2023 -0800

    MIPS: vpe-mt: drop physical_memsize
    
    [ Upstream commit 91dc288f4edf0d768e46c2c6d33e0ab703403459 ]
    
    When neither LANTIQ nor MIPS_MALTA is set, 'physical_memsize' is not
    declared. This causes the build to fail with:
    
    mips-linux-ld: arch/mips/kernel/vpe-mt.o: in function `vpe_run':
    arch/mips/kernel/vpe-mt.c:(.text.vpe_run+0x280): undefined reference to `physical_memsize'
    
    LANTIQ is not using 'physical_memsize' and MIPS_MALTA's use of it is
    self-contained in mti-malta/malta-dtshim.c.
    Use of physical_memsize in vpe-mt.c appears to be unused, so eliminate
    this loader mode completely and require VPE programs to be compiled with
    DFLT_STACK_SIZE and DFLT_HEAP_SIZE defined.
    
    Fixes: 9050d50e2244 ("MIPS: lantiq: Set physical_memsize")
    Fixes: 1a2a6d7e8816 ("MIPS: APRP: Split VPE loader into separate files.")
    Signed-off-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
    Reported-by: kernel test robot <lkp@xxxxxxxxx>
    Link: https://lore.kernel.org/all/202302030625.2g3E98sY-lkp@xxxxxxxxx/
    Cc: Dengcheng Zhu <dzhu@xxxxxxxxxxxx>
    Cc: John Crispin <john@xxxxxxxxxxx>
    Cc: Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx>
    Cc: Philippe Mathieu-Daudé <philmd@xxxxxxxxxx>
    Cc: "Steven J. Hill" <Steven.Hill@xxxxxxxxxx>
    Cc: Qais Yousef <Qais.Yousef@xxxxxxxxxx>
    Cc: Yang Yingliang <yangyingliang@xxxxxxxxxx>
    Cc: Hauke Mehrtens <hauke@xxxxxxxxxx>
    Cc: James Hogan <jhogan@xxxxxxxxxx>
    Cc: linux-mips@xxxxxxxxxxxxxxx
    Signed-off-by: Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/arch/mips/include/asm/vpe.h b/arch/mips/include/asm/vpe.h
index 80e70dbd1f641..012731546cf60 100644
--- a/arch/mips/include/asm/vpe.h
+++ b/arch/mips/include/asm/vpe.h
@@ -104,7 +104,6 @@ struct vpe_control {
 	struct list_head tc_list;       /* Thread contexts */
 };
 
-extern unsigned long physical_memsize;
 extern struct vpe_control vpecontrol;
 extern const struct file_operations vpe_fops;
 
diff --git a/arch/mips/kernel/vpe-mt.c b/arch/mips/kernel/vpe-mt.c
index 9fd7cd48ea1d2..496ed8f362f62 100644
--- a/arch/mips/kernel/vpe-mt.c
+++ b/arch/mips/kernel/vpe-mt.c
@@ -92,12 +92,11 @@ int vpe_run(struct vpe *v)
 	write_tc_c0_tchalt(read_tc_c0_tchalt() & ~TCHALT_H);
 
 	/*
-	 * The sde-kit passes 'memsize' to __start in $a3, so set something
-	 * here...  Or set $a3 to zero and define DFLT_STACK_SIZE and
-	 * DFLT_HEAP_SIZE when you compile your program
+	 * We don't pass the memsize here, so VPE programs need to be
+	 * compiled with DFLT_STACK_SIZE and DFLT_HEAP_SIZE defined.
 	 */
+	mttgpr(7, 0);
 	mttgpr(6, v->ntcs);
-	mttgpr(7, physical_memsize);
 
 	/* set up VPE1 */
 	/*
diff --git a/arch/mips/lantiq/prom.c b/arch/mips/lantiq/prom.c
index a26322ff57e01..8cf1868540312 100644
--- a/arch/mips/lantiq/prom.c
+++ b/arch/mips/lantiq/prom.c
@@ -25,12 +25,6 @@
 DEFINE_SPINLOCK(ebu_lock);
 EXPORT_SYMBOL_GPL(ebu_lock);
 
-/*
- * This is needed by the VPE loader code, just set it to 0 and assume
- * that the firmware hardcodes this value to something useful.
- */
-unsigned long physical_memsize = 0L;
-
 /*
  * this struct is filled by the soc specific detection code and holds
  * information about the specific soc type, revision and name



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux