1. 08 Nov, 2017 7 commits
    • Heiko Carstens's avatar
      s390: avoid undefined behaviour · ead7a22e
      Heiko Carstens authored
      At a couple of places smatch emits warnings like this:
      
          arch/s390/mm/vmem.c:409 vmem_map_init() warn:
              right shifting more than type allows
      
      In fact shifting a signed type right is undefined. Avoid this and add
      an unsigned long cast. The shifted values are always positive.
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      ead7a22e
    • Heiko Carstens's avatar
      s390/disassembler: generate opcode tables from text file · 8bc1e4ec
      Heiko Carstens authored
      The current way of adding new instructions to the opcode tables is
      painful and error prone. Therefore add, similar to binutils, a text
      file which contains all opcodes and the corresponding mnemonics and
      instruction formats.
      
      A small gen_opcode_table tool then generates a header file with the
      required enums and opcode table initializers at the prepare step of
      the kernel build.
      
      This way only a simple text file has to be maintained, which can be
      rather easily extended.
      
      Unlike before where there were plenty of opcode tables and a large
      switch statement to find the correct opcode table, there is now only
      one opcode table left which contains all instructions. A second opcode
      offset table now contains offsets within the opcode table to find
      instructions which have the same opcode prefix. In order to save space
      all 1-byte opcode instructions are grouped together at the end of the
      opcode table. This is also quite similar to like it was before.
      
      In addition also move and change code and definitions within the
      disassembler. As a side effect this reduces the size required for the
      code and opcode tables by ~1.5k.
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      8bc1e4ec
    • Heiko Carstens's avatar
      s390/disassembler: remove insn_to_mnemonic() · dac6dc26
      Heiko Carstens authored
      insn_to_mnemonic() was introduced ages ago for KVM debugging, but is
      unused in the meantime. Therefore remove it.
      Acked-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      dac6dc26
    • Arnd Bergmann's avatar
      s390/dasd: avoid calling do_gettimeofday() · 399c5acd
      Arnd Bergmann authored
      do_gettimeofday() is deprecated because it's not y2038-safe on
      32-bit architectures. Since it is basically a wrapper around
      ktime_get_real_ts64(), we can just call that function directly
      instead.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      [sth@linux.vnet.ibm.com: fix build]
      Signed-off-by: default avatarStefan Haberland <sth@linux.vnet.ibm.com>
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      399c5acd
    • Heiko Carstens's avatar
      s390: remove named saved segment support · 978fa72e
      Heiko Carstens authored
      Remove the support to create a z/VM named saved segment (NSS). This
      feature is not supported since quite a while in favour of jump labels,
      function tracing and (now) CPU alternatives. All of these features
      require to write to the kernel text section which is not possible if
      the kernel is contained within an NSS.
      
      Given that memory savings are minimal if kernel images are shared and
      in addition updates of shared images are painful, the NSS feature can
      be removed.
      Reviewed-by: default avatarHendrik Brueckner <brueckner@linux.vnet.ibm.com>
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      978fa72e
    • Harald Freudenberger's avatar
      s390/archrandom: Reconsider s390 arch random implementation · f44fa887
      Harald Freudenberger authored
      The reworked version of the random device driver now calls
      the arch_get_random_* functions on a very high frequency.
      It does about 100.000 calls to arch_get_random_long for
      providing 10 MB via /dev/urandom. Each invocation was
      fetching entropy from the hardware random generator which
      has a rate limit of about 4 MB/s. As the trng invocation
      waits until enough entropy is gathered, the random device
      driver is slowed down dramatically.
      
      The s390 true random generator is not designed for such
      a high rate. The TRNG is more designed to be used together
      with the arch_get_random_seed_* functions. This is similar
      to the way how powerpc has implemented their arch random
      functionality.
      
      This patch removes the invocations of the s390 TRNG for
      arch_get_random_long() and arch_get_random_int() but leaving
      the invocations for arch_get_random_seed_long() and
      arch_get_random_seed_int(). So the s390 arch random
      implementation now contributes high quality entropy to
      the kernel random device for reseeding.
      Signed-off-by: default avatarHarald Freudenberger <freude@linux.vnet.ibm.com>
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      f44fa887
    • Christian Borntraeger's avatar
      s390/pci: do not require AIS facility · 48070c73
      Christian Borntraeger authored
      As of today QEMU does not provide the AIS facility to its guest.  This
      prevents Linux guests from using PCI devices as the ais facility is
      checked during init. As this is just a performance optimization, we can
      move the ais check into the code where we need it (calling the SIC
      instruction). This is used at initialization and on interrupt. Both
      places do not require any serialization, so we can simply skip the
      instruction.
      
      Since we will now get all interrupts, we can also avoid the 2nd scan.
      As we can have multiple interrupts in parallel we might trigger spurious
      irqs more often for the non-AIS case but the core code can handle that.
      Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
      Reviewed-by: default avatarPierre Morel <pmorel@linux.vnet.ibm.com>
      Reviewed-by: default avatarHalil Pasic <pasic@linux.vnet.ibm.com>
      Acked-by: default avatarSebastian Ott <sebott@linux.vnet.ibm.com>
      Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
      48070c73
  2. 03 Nov, 2017 2 commits
  3. 02 Nov, 2017 2 commits
  4. 26 Oct, 2017 3 commits
  5. 23 Oct, 2017 3 commits
  6. 19 Oct, 2017 5 commits
  7. 18 Oct, 2017 7 commits
  8. 16 Oct, 2017 6 commits
  9. 12 Oct, 2017 1 commit
  10. 09 Oct, 2017 4 commits