1. 10 6月, 2016 4 次提交
    • D
      KVM: s390: interface to query and configure cpu subfunctions · 0a763c78
      David Hildenbrand 提交于
      We have certain instructions that indicate available subfunctions via
      a query subfunction (crypto functions and ptff), or via a test bit
      function (plo).
      
      By exposing these "subfunction blocks" to user space, we allow user space
      to
      1) query available subfunctions and make sure subfunctions won't get lost
         during migration - e.g. properly indicate them via a CPU model
      2) change the subfunctions to be reported to the guest (even adding
         unavailable ones)
      
      This mechanism works just like the way we indicate the stfl(e) list to
      user space.
      
      This way, user space could even emulate some subfunctions in QEMU in the
      future. If this is ever applicable, we have to make sure later on, that
      unsupported subfunctions result in an intercept to QEMU.
      
      Please note that support to indicate them to the guest is still missing
      and requires hardware support. Usually, the IBC takes already care of these
      subfunctions for migration safety. QEMU should make sure to always set
      these bits properly according to the machine generation to be emulated.
      
      Available subfunctions are only valid in combination with STFLE bits
      retrieved via KVM_S390_VM_CPU_MACHINE and enabled via
      KVM_S390_VM_CPU_PROCESSOR. If the applicable bits are available, the
      indicated subfunctions are guaranteed to be correct.
      Signed-off-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com>
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      0a763c78
    • D
      KVM: s390: forward ESOP if available · 22be5a13
      David Hildenbrand 提交于
      ESOP guarantees that during a protection exception, bit 61 of real location
      168-175 will only be set to 1 if it was because of ALCP or DATP. If the
      exception is due to LAP or KCP, the bit will always be set to 0.
      
      The old SOP definition allowed bit 61 to be unpredictable in case of LAP
      or KCP in some conditions. So ESOP replaces this unpredictability by
      a guarantee.
      
      Therefore, we can directly forward ESOP if it is available on our machine.
      We don't have to do anything when ESOP is disabled - the guest will simply
      expect unpredictable values. Our guest access functions are already
      handling ESOP properly.
      
      Please note that future functionality in KVM will require knowledge about
      ESOP being enabled for a guest or not.
      Reviewed-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      Signed-off-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com>
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      22be5a13
    • D
      KVM: s390: interface to query and configure cpu features · 15c9705f
      David Hildenbrand 提交于
      For now, we only have an interface to query and configure facilities
      indicated via STFL(E). However, we also have features indicated via
      SCLP, that have to be indicated to the guest by user space and usually
      require KVM support.
      
      This patch allows user space to query and configure available cpu features
      for the guest.
      
      Please note that disabling a feature doesn't necessarily mean that it is
      completely disabled (e.g. ESOP is mostly handled by the SIE). We will try
      our best to disable it.
      
      Most features (e.g. SCLP) can't directly be forwarded, as most of them need
      in addition to hardware support, support in KVM. As we later on want to
      turn these features in KVM explicitly on/off (to simulate different
      behavior), we have to filter all features provided by the hardware and
      make them configurable.
      Signed-off-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com>
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      15c9705f
    • J
      KVM: s390: Add sthyi emulation · 95ca2cb5
      Janosch Frank 提交于
      Store Hypervisor Information is an emulated z/VM instruction that
      provides a guest with basic information about the layers it is running
      on. This includes information about the cpu configuration of both the
      machine and the lpar, as well as their names, machine model and
      machine type. This information enables an application to determine the
      maximum capacity of CPs and IFLs available to software.
      
      The instruction is available whenever the facility bit 74 is set,
      otherwise executing it results in an operation exception.
      
      It is important to check the validity flags in the sections before
      using data from any structure member. It is not guaranteed that all
      members will be valid on all machines / machine configurations.
      Signed-off-by: NJanosch Frank <frankja@linux.vnet.ibm.com>
      Reviewed-by: NDavid Hildenbrand <dahi@linux.vnet.ibm.com>
      Signed-off-by: NChristian Borntraeger <borntraeger@de.ibm.com>
      95ca2cb5
  2. 20 4月, 2016 2 次提交
  3. 16 4月, 2016 1 次提交
  4. 01 4月, 2016 1 次提交
  5. 08 3月, 2016 1 次提交
  6. 07 3月, 2016 1 次提交
  7. 26 2月, 2016 1 次提交
    • T
      net: Facility to report route quality of connected sockets · a87cb3e4
      Tom Herbert 提交于
      This patch add the SO_CNX_ADVICE socket option (setsockopt only). The
      purpose is to allow an application to give feedback to the kernel about
      the quality of the network path for a connected socket. The value
      argument indicates the type of quality report. For this initial patch
      the only supported advice is a value of 1 which indicates "bad path,
      please reroute"-- the action taken by the kernel is to call
      dst_negative_advice which will attempt to choose a different ECMP route,
      reset the TX hash for flow label and UDP source port in encapsulation,
      etc.
      
      This facility should be useful for connected UDP sockets where only the
      application can provide any feedback about path quality. It could also
      be useful for TCP applications that have additional knowledge about the
      path outside of the normal TCP control loop.
      Signed-off-by: NTom Herbert <tom@herbertland.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a87cb3e4
  8. 10 2月, 2016 1 次提交
  9. 19 1月, 2016 1 次提交
  10. 07 1月, 2016 1 次提交
  11. 05 1月, 2016 1 次提交
  12. 16 12月, 2015 1 次提交
  13. 16 11月, 2015 1 次提交
  14. 09 11月, 2015 1 次提交
  15. 18 9月, 2015 1 次提交
  16. 17 9月, 2015 2 次提交
  17. 04 8月, 2015 1 次提交
  18. 06 3月, 2015 2 次提交
  19. 10 2月, 2015 1 次提交
    • M
      s390/hypfs: Add diagnose 0c support · 34c0dad7
      Michael Holzheu 提交于
      With this feature, you can read the CPU performance metrics provided by the
      z/VM diagnose 0C. This then allows to get the management time for each
      online CPU of the guest where the diagnose is executed.
      
      The new debugfs file /sys/kernel/debug/s390_hypfs/diag_0c exports the
      diag0C binary data to user space via an open/read/close interface.
      
      The binary data consists out of a header structure followed by an
      array that contains the diagnose 0c data for each online CPU.
      Signed-off-by: NMichael Holzheu <holzheu@linux.vnet.ibm.com>
      Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
      34c0dad7
  20. 09 2月, 2015 1 次提交
  21. 23 1月, 2015 4 次提交
  22. 18 12月, 2014 1 次提交
  23. 06 12月, 2014 1 次提交
    • A
      net: sock: allow eBPF programs to be attached to sockets · 89aa0758
      Alexei Starovoitov 提交于
      introduce new setsockopt() command:
      
      setsockopt(sock, SOL_SOCKET, SO_ATTACH_BPF, &prog_fd, sizeof(prog_fd))
      
      where prog_fd was received from syscall bpf(BPF_PROG_LOAD, attr, ...)
      and attr->prog_type == BPF_PROG_TYPE_SOCKET_FILTER
      
      setsockopt() calls bpf_prog_get() which increments refcnt of the program,
      so it doesn't get unloaded while socket is using the program.
      
      The same eBPF program can be attached to multiple sockets.
      
      User task exit automatically closes socket which calls sk_filter_uncharge()
      which decrements refcnt of eBPF program
      Signed-off-by: NAlexei Starovoitov <ast@plumgrid.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      89aa0758
  24. 19 11月, 2014 1 次提交
  25. 12 11月, 2014 1 次提交
    • E
      net: introduce SO_INCOMING_CPU · 2c8c56e1
      Eric Dumazet 提交于
      Alternative to RPS/RFS is to use hardware support for multiple
      queues.
      
      Then split a set of million of sockets into worker threads, each
      one using epoll() to manage events on its own socket pool.
      
      Ideally, we want one thread per RX/TX queue/cpu, but we have no way to
      know after accept() or connect() on which queue/cpu a socket is managed.
      
      We normally use one cpu per RX queue (IRQ smp_affinity being properly
      set), so remembering on socket structure which cpu delivered last packet
      is enough to solve the problem.
      
      After accept(), connect(), or even file descriptor passing around
      processes, applications can use :
      
       int cpu;
       socklen_t len = sizeof(cpu);
      
       getsockopt(fd, SOL_SOCKET, SO_INCOMING_CPU, &cpu, &len);
      
      And use this information to put the socket into the right silo
      for optimal performance, as all networking stack should run
      on the appropriate cpu, without need to send IPI (RPS/RFS).
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2c8c56e1
  26. 17 10月, 2014 1 次提交
  27. 09 10月, 2014 1 次提交
    • M
      s390: add support for vector extension · 80703617
      Martin Schwidefsky 提交于
      The vector extension introduces 32 128-bit vector registers and a set of
      instruction to operate on the vector registers.
      
      The kernel can control the use of vector registers for the problem state
      program with a bit in control register 0. Once enabled for a process the
      kernel needs to retain the content of the vector registers on context
      switch. The signal frame is extended to include the vector registers.
      Two new register sets NT_S390_VXRS_LOW and NT_S390_VXRS_HIGH are added
      to the regset interface for the debugger and core dumps.
      Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
      80703617
  28. 25 8月, 2014 1 次提交
  29. 12 8月, 2014 2 次提交
  30. 21 7月, 2014 1 次提交