Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) 2003-03-22  Ralph Siemsen <ralphs@netwinder.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) 	* Reformat all but softfloat files to get a consistent coding style.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3) 	  Used "indent -kr -i8 -ts8 -sob -l132 -ss" and a few manual fixups.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) 	* Removed dead code and fixed function protypes to match definitions.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5) 	* Consolidated use of (opcode && MASK_ARITHMETIC_OPCODE) >> 20.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6) 	* Make 80-bit precision a compile-time option. (1%)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7) 	* Only initialize FPE state once in repeat-FP situations. (6%)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) 2002-01-19  Russell King <rmk@arm.linux.org.uk>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) 	* fpa11.h - Add documentation
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) 	          - remove userRegisters pointer from this structure.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 	          - add new method to obtain integer register values.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) 	* softfloat.c - Remove float128
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 	* softfloat.h - Remove float128
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 	* softfloat-specialize - Remove float128
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 	* The FPA11 structure is not a kernel-specific data structure.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 	  It is used by users of ptrace to examine the values of the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 	  floating point registers.  Therefore, any changes to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 	  FPA11 structure (size or position of elements contained
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 	  within) have to be well thought out.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 	* Since 128-bit float requires the FPA11 structure to change
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 	  size, it has been removed.  128-bit float is currently unused,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 	  and needs various things to be re-worked so that we won't
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 	  overflow the available space in the task structure.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) 	* The changes are designed to break any patch that goes on top
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 	  of this code, so that the authors properly review their changes.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 1999-08-19  Scott Bambrough  <scottb@netwinder.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 	* fpmodule.c - Changed version number to 0.95
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 	* fpa11.h - modified FPA11, FPREG structures
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 	* fpa11.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) 	* fpa11_cpdo.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 	* fpa11_cpdt.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 	* fpa11_cprt.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) 	* single_cpdo.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 	* double_cpdo.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) 	* extended_cpdo.c - Changes due to FPA11, FPREG structure alterations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) 	* I discovered several bugs.  First and worst is that the kernel
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) 	  passes in a pointer to the FPE's state area.	This is defined
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) 	  as a struct user_fp (see user.h).  This pointer was cast to a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) 	  FPA11*.  Unfortunately FPA11 and user_fp are of different sizes;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) 	  user_fp is smaller.  This meant that the FPE scribbled on things
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) 	  below its area, which is bad, as the area is in the thread_struct
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) 	  embedded in the process task structure.  Thus we were scribbling
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) 	  over one of the most important structures in the entire OS.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) 	* user_fp and FPA11 have now been harmonized.  Most of the changes
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) 	  in the above code were dereferencing problems due to moving the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) 	  register type out of FPREG, and getting rid of the union variable
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) 	  fpvalue.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) 	* Second I noticed resetFPA11 was not always being called for a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) 	  task.  This should happen on the first floating point exception
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) 	  that occurs.	It is controlled by init_flag in FPA11.  The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) 	  comment in the code beside init_flag state the kernel guarantees
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) 	  this to be zero.  Not so.  I found that the kernel recycles task
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) 	  structures, and that recycled ones may not have init_flag zeroed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) 	  I couldn't even find anything that guarantees it is zeroed when
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) 	  when the task structure is initially allocated.  In any case
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) 	  I now initialize the entire FPE state in the thread structure to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67) 	  zero when allocated and recycled.  See alloc_task_struct() and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) 	  flush_thread() in arch/arm/process.c.  The change to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) 	  alloc_task_struct() may not be necessary, but I left it in for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) 	  completeness (better safe than sorry).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) 1998-11-23  Scott Bambrough  <scottb@netwinder.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) 	* README.FPE - fix typo in description of lfm/sfm instructions
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) 	* NOTES - Added file to describe known bugs/problems
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) 	* fpmodule.c - Changed version number to 0.94
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) 1998-11-20  Scott Bambrough  <scottb@netwinder.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) 	* README.FPE - fix description of URD, NRM instructions
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81) 	* TODO - remove URD, NRM instructions from TODO list
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 82) 	* single_cpdo.c - implement URD, NRM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 83) 	* double_cpdo.c - implement URD, NRM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 84) 	* extended_cpdo.c - implement URD, NRM
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 85) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 86) 1998-11-19  Scott Bambrough  <scottb@netwinder.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 87) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 88) 	* ChangeLog - Added this file to track changes made.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 89) 	* fpa11.c - added code to initialize register types to typeNone
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 90) 	* fpa11_cpdt.c - fixed bug in storeExtended (typeExtended changed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 91) 	  typeDouble in switch statement)