1. 17 4月, 2021 1 次提交
  2. 09 3月, 2021 1 次提交
  3. 08 3月, 2021 2 次提交
  4. 24 2月, 2021 5 次提交
  5. 14 2月, 2021 8 次提交
    • J
      s390/qdio: remove 'merge_pending' mechanism · 2223318c
      Julian Wiedmann 提交于
      For non-QEBSM devices, get_buf_states() merges PENDING and EMPTY buffers
      into a single group of finished buffers. To allow the upper-layer driver
      to differentiate between the two states, qdio_check_pending() looks at
      each buffer's state again and sets the sbal_state flag to
      QDIO_OUTBUF_STATE_FLAG_PENDING accordingly.
      
      So effectively we're spending overhead on _every_ Output Queue
      inspection, just to avoid some additional TX completion calls in case
      a group of buffers has completed with mixed EMPTY / PENDING state.
      Given that PENDING buffers should rarely occur, this is a bad trade-off.
      In particular so as the additional checks in get_buf_states() affect
      _all_ device types (even those that don't use the PENDING state).
      
      Rip it all out, and just report the PENDING completions separately as
      we already do for QEBSM devices.
      Signed-off-by: NJulian Wiedmann <jwi@linux.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      2223318c
    • J
      s390/qdio: improve handling of PENDING buffers for QEBSM devices · 7940eaf2
      Julian Wiedmann 提交于
      For QEBSM devices the 'merge_pending' mechanism in get_buf_states()
      doesn't apply, and we can actually get SLSB_P_OUTPUT_PENDING returned.
      
      So for this case propagating the PENDING state to the driver via the
      queue's sbal_state doesn't make sense and creates unnecessary overhead.
      Instead introduce a new QDIO_ERROR_* flag that gets passed to the
      driver, and triggers the same processing as if the buffers were flagged
      as QDIO_OUTBUF_STATE_FLAG_PENDING.
      Signed-off-by: NJulian Wiedmann <jwi@linux.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      7940eaf2
    • H
      s390/time: remove get_tod_clock_ext() · 7ef37dd7
      Heiko Carstens 提交于
      Remove get_tod_clock_ext() and the STORE_CLOCK_EXT_SIZE define. This
      enforces all users of the existing low level functions to use a union
      tod_clock.
      
      This way there is now a compile time check for the correct time and
      therefore also if the size of the argument matches what will be
      written to by the STORE CLOCK EXTENDED instruction.
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      7ef37dd7
    • H
      s390/time: convert tod_clock_base to union · f8d8977a
      Heiko Carstens 提交于
      Convert tod_clock_base to union tod_clock. This simplifies quite a bit
      of code and also fixes a bug in read_persistent_clock64();
      
      void read_persistent_clock64(struct timespec64 *ts)
      {
              __u64 delta;
      
              delta = initial_leap_seconds + TOD_UNIX_EPOCH;
              get_tod_clock_ext(clk);
              *(__u64 *) &clk[1] -= delta;
              if (*(__u64 *) &clk[1] > delta)
                      clk[0]--;
              ext_to_timespec64(clk, ts);
      }
      
      Assume &clk[1] == 3 and delta == 2; then after the substraction the if
      condition becomes true and the epoch part of the clock is decremented
      by one because of an assumed overflow, even though there is none.
      
      Fix this by using 128 bit arithmetics and let the compiler do the
      right thing:
      
      void read_persistent_clock64(struct timespec64 *ts)
      {
              union tod_clock clk;
              u64 delta;
      
              delta = initial_leap_seconds + TOD_UNIX_EPOCH;
              store_tod_clock_ext(&clk);
              clk.eitod -= delta;
              ext_to_timespec64(&clk, ts);
      }
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      f8d8977a
    • H
      s390/time: introduce new store_tod_clock_ext() · cc2c7db2
      Heiko Carstens 提交于
      Introduce new store_tod_clock_ext() function, which is the same like
      store_tod_clock_ext_cc() except that it doesn't return a condition
      code.
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      cc2c7db2
    • H
      s390/time: rename store_tod_clock_ext() and use union tod_clock · 530f639f
      Heiko Carstens 提交于
      Rename store_tod_clock_ext() to store_tod_clock_ext_cc() to reflect
      that it returns a condition code and also use union tod_clock as
      parameter.
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      530f639f
    • H
      s390/time: introduce union tod_clock · e4101be5
      Heiko Carstens 提交于
      Introduce union tod_clock which is supposed to be used to decode and
      access various fields of the result of STORE CLOCK EXTENDED.
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      e4101be5
    • S
      s390: add stack for machine check handler · b61b1595
      Sven Schnelle 提交于
      The previous code used the normal kernel stack for machine checks.
      This is problematic when a machine check interrupts a system call
      or interrupt handler right at the beginning where registers are set up.
      
      Assume system_call is interrupted at the first instruction and a machine
      check is triggered. The machine check handler is called, checks the PSW
      to see whether it is coming from user space, notices that it is already
      in kernel mode but %r15 still contains the user space stack. This would
      lead to a kernel crash.
      
      There are basically two ways of fixing that: Either using the 'critical
      cleanup' approach which compares the address in the PSW to see whether
      it is already at a point where the stack has been set up, or use an extra
      stack for the machine check handler.
      
      For simplicity, we will go with the second approach and allocate an extra
      stack. This adds some memory overhead for large systems, but usually large
      system have plenty of memory so this isn't really a concern. But it keeps
      the mchk stack setup simple and less error prone.
      
      Fixes: 0b0ed657 ("s390: remove critical section cleanup from entry.S")
      Signed-off-by: NSven Schnelle <svens@linux.ibm.com>
      Cc: <stable@kernel.org> # v5.8+
      Reviewed-by: NHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: NVasily Gorbik <gor@linux.ibm.com>
      b61b1595
  6. 11 2月, 2021 1 次提交
  7. 09 2月, 2021 12 次提交
  8. 30 1月, 2021 1 次提交
  9. 27 1月, 2021 1 次提交
  10. 19 1月, 2021 6 次提交
  11. 30 12月, 2020 1 次提交
  12. 16 12月, 2020 1 次提交