1. 14 Nov, 2015 1 commit
    • Gwenhael Goavec-Merou's avatar
      Add (implicit) support for musl libc · 8cd0c73f
      Gwenhael Goavec-Merou authored
      
      This is mostly achieved by fixing or refining the inclusion of header
      files and replacing glibc-specific ifdefs with more generic ones.
      
       - <sys/io.h>: Contains iopl(2) and x86 I/O port access functions (inb, outb etc).
                     Generally Linux-specific but also availble on debian/kFreeBSD.
                     Provided by glibc as well as musl and uclibc.
                     Include it if we are running Linux or if glibc is detected.
       - <sys/fcntl.h>: should be (and is) replaced by <fcntl.h> (without the
          			  "sys" prefix).
       - <linux/spi/spidev.h>: Does not include all necessary headers, namely
                               _IOC_SIZEBITS that is used in the definition of
                               SPI_MSGSIZE is not brought in via <linux/ioctl.h>
                               but instead we relied so far on glibc's including
                               it via <sys/ioctl.h>. Change that to explicitly
                               including <linux/ioctl.h>.
       - <endian.h>: Would also be available in musl but there is no easy way
                     to detect it so we do not try yet.
      
      Corresponding to flashrom svn r1898.
      
      The bug report and initial patches were
      Signed-off-by: default avatarGwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com>
      Signed-off-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      Acked-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      8cd0c73f
  2. 23 May, 2015 1 commit
  3. 10 Feb, 2015 1 commit
  4. 10 Jan, 2015 2 commits
    • Stefan Tauner's avatar
      Refinements for DragonflyBSD · 8d21ff1d
      Stefan Tauner authored
      
       - /usr/include/cpu/param.h defines PAGE_MASK already, hence use another
         name for the respective macro in nicintel_eeprom.c.
       - Since DragonflyBSD 3.6 DPorts is used as the default package manager.
         Therefore we should use /usr/local/ instead of /usr/pkg/ on default
         to fetch libraries.
      
      Corresponding to flashrom svn r1866.
      Signed-off-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      Acked-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      8d21ff1d
    • Stefan Tauner's avatar
      Unify target OS and CPU architecture checks · b0eee9b8
      Stefan Tauner authored
      
      We do CPU architecture checks once for the makefile in arch.h and
      once for HW access abstraction in hwaccess.c. This patch unifies
      related files so that they can share the checks to improve
      maintainability and reduce the chance of inconsistencies.
      Furthermore, it refines some of the definitions, which
       - adds "support" for AARCH64 and PPC64,
       - adds big-endian handling on arm as well as LE handling on PPC64,
       - fixes compilation of internal.c on AARCH64 and PPC64.
      
      Additionally, this patch continues to unify all OS checks in
      flashrom by adding a new helper macro IS_WINDOWS.
      
      The old header file for architecture checking is renamed to platform.h
      to reflect its broader scope and all new macros are add in there.
      
      Corresponding to flashrom svn r1864.
      Signed-off-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      Acked-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      b0eee9b8
  5. 12 Sep, 2013 1 commit
  6. 25 Jul, 2013 1 commit
  7. 04 Feb, 2013 1 commit
    • Stefan Tauner's avatar
      Fix building for MacOSX · e038e908
      Stefan Tauner authored
      
      - Add a new macro named IS_MACOSX to hwaccess.c and use it to enable iopl().
        This was broken since r1638. This fix does *not* restore the very permissive
        concept where iopl() was activated in an #else branch that was inplace before
        r1638.
      - Make printing the image file's size in flashrom.c platform independent.
      
      Bonus: remove definitions of off64_t and lseek64 which are not necessary
      anymore for about 1000 commits.
      
      Thanks to SJ for reporting the issue and testing the solution.
      
      Corresponding to flashrom svn r1648.
      Signed-off-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      Acked-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
      e038e908
  8. 27 Aug, 2012 1 commit
  9. 09 Aug, 2012 1 commit
    • Carl-Daniel Hailfinger's avatar
      Portability fixes and cleanups · 60d9bd26
      Carl-Daniel Hailfinger authored
      
      Move Mac OS X IOKit/DirectHW availability checks in the Makefile from
      compiler check to pciutils check.
      
      Print the compiler error messages for feature detection.
      
      Add DOS libpci in the Makefile includes only if a PCI-based programmer
      was requested.
      
      Restrict mmap usage in ich_descriptors_tool to Unix style systems.
      
      Build ich_descriptors_tool with the correct .exe extension on
      DOS/Windows.
      
      Build ich_descriptors_tool by default on x86. (Patch by Stefan Tauner)
      
      Print the Windows version instead of "unknown machine" on Windows.
      
      Don't #define our own __DARWIN__, use the standard OS X detection
      method.
      
      Update the README.
      
      Add more generated files to svn:ignore
      
      Corresponding to flashrom svn r1567.
      Signed-off-by: default avatarCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
      Acked-by: default avatarCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
      60d9bd26
  10. 25 Feb, 2012 1 commit
  11. 13 Feb, 2012 1 commit
  12. 28 Jul, 2011 1 commit
  13. 18 Mar, 2011 1 commit
  14. 06 Oct, 2010 2 commits
  15. 30 Sep, 2010 1 commit
  16. 29 Jul, 2010 1 commit
  17. 17 Jul, 2010 1 commit
  18. 02 Jul, 2010 1 commit
  19. 25 Jun, 2010 1 commit
  20. 26 May, 2010 1 commit
    • Carl-Daniel Hailfinger's avatar
      Handle the following architectures in generic flashrom code · cceafa2a
      Carl-Daniel Hailfinger authored
      
      - x86/x86_64 (little endian)
      - PowerPC (big endian)
      - MIPS (big+little endian)
      
      No changes to programmer specific code. This means any drivers with MMIO
      access will _not_ suddenly start working on big endian systems, but with
      this patch everything is in place to fix them.
      
      Compilation should work on all architectures listed above for all
      drivers except nic3com and nicrealtek which require PCI Port IO which is
      x86-only for now.
      
      To compile without nic3com and nicrealtek, run
      make distclean
      make CONFIG_NIC3COM=no CONFIG_NICREALTEK=no
      
      Thanks to Misha Manulis for testing early versions of this patch on
      PowerPC (big endian) with the satasii programmer.
      Thanks to Segher Boessenkool for design review and for helping out with
      compiler tricks and pointing out that we need eieio on PowerPC.
      Thanks to Vladimir Serbinenko for compile testing on MIPS (little
      endian) and PowerPC (big endian) and for runtime testing on MIPS (little
      endian).
      Thanks to David Daney for compile testing on MIPS (big endian).
      Thanks to Uwe Hermann for compile and runtime testing on x86_64.
      
      DO NOT RUN flashrom ON NON-X86 AFTER APPLYING THIS PATCH!
      This patch only provides the infrastructure, but does not convert any
      drivers, so flashrom will compile, but it won't do the right thing on
      non-x86 platforms.
      
      Corresponding to flashrom svn r1013.
      Signed-off-by: default avatarCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
      Acked-by: default avatarMisha Manulis <misha@manulis.com>
      Acked-by: default avatarVladimir 'phcoder/φ-coder' Serbinenko <phcoder@gmail.com>
      Acked-by: default avatarUwe Hermann <uwe@hermann-uwe.de>
      Acked-by: default avatarSegher Boessenkool <segher@kernel.crashing.org>
      cceafa2a
  21. 16 Mar, 2010 1 commit
  22. 13 Mar, 2010 1 commit
  23. 12 Feb, 2010 1 commit
  24. 12 Jan, 2010 1 commit
  25. 08 Jan, 2010 1 commit
  26. 14 Dec, 2009 1 commit