1. 20 May, 2019 6 commits
  2. 17 May, 2019 5 commits
  3. 16 May, 2019 12 commits
    • Maarten Lankhorst's avatar
      tests/kms_chamelium: Fix *-cmp-random and *-crc-random tests, v4. · 555019f8
      Maarten Lankhorst authored
      The random tests allowed potentially invalid things:
      - 1x1 fb's to be created. Force a minimum of 32 on YUV so a scaled
        planar format plane will be at least 16x16. This will fix
        scaled/planar format support in i915 and avoid a div by zero when
        calculating a value modulo h/2 and w/2.
      - Downscaling to any amount, restrict it to 2x to make the test pass.
      - Some hw may not allow scaling, in those cases we should fallback
        to no scaling at all.
      - Attempting to configure a minimum of 4 planes, instead of a maximum.
        This fails with a null pointer deref if the hw doesn't have 4
        configurable overlay planes.
      
      Changes since v1:
      - Enforce a minimum displayed size of 16x16 for intel only,
        otherwise it's 1x1.
      - Fix comments.
      Changes since v2:
      - Fix comments harder.
      - Pick a random format and its modifier from the plane itself,
        instead of using igt_format_array_fill(). This will cause the test
        to use all valid combinations of modifiers and formats.
      - Set minimum dimension to 8 for !yuv, and 16 for YUV.
      - Generate format / modifier before
      Changes since v3:
      - Rebase.
      
      Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
      Signed-off-by: 's avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Acked-by: Simon Ser <simon.ser@intel.com> #v3
      555019f8
    • Maarten Lankhorst's avatar
      lib/igt_fb: Use cairo conversion in igt_fb_convert_with_stride, v4. · fddfda65
      Maarten Lankhorst authored
      Ever since commit 3fa65f4b ("fb: Add support for conversions
      through pixman") we can generate a valid cairo surface for any plane,
      use this to avoid having to implement our own conversion routine.
      
      Instead of duplicating this functionality in igt_fb_convert_with_stride,
      we can simply convert this to a few cairo calls, because we now support
      cairo calls to any of the supported framebuffer formats.
      
      This is required to make this function more generic, and convert from any
      format/modifier to any other format/modifier.
      
      Changes since v1:
      - Return fb_id in the cairo case.
      Changes since v2:
      - Remove the manual conversion fallback.
      Changes since v3:
      - Integrate VC4 conversion routines.
      Signed-off-by: 's avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
      Reviewed-by: Juha-Pekka Heikkilä's avatarJuha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
      fddfda65
    • Simon Ser's avatar
      lib/igt_audio: use double instead of int16_t · 2d41b519
      Simon Ser authored
      In order to be able to generate S32_LE signals, we need a higher precision than
      S16_LE. Change the signal generation code to use double instead of int16_t and
      introduce a new helper to fill a buffer with S16_LE samples. We already use
      arrays of doubles elsewhere (see audio_signal_detect). Similar format-specific
      helpers will be added for S32_LE in the future.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      2d41b519
    • Simon Ser's avatar
      tests/kms_chamelium: don't abort audio test on first fail · 250bc278
      Simon Ser authored
      The audio test is repeated with a few different frequencies. When the test
      fails for one frequency, continue testing other frequencies so that we get a
      better understanding of the situation: is only one frequency failing, or are
      all of them failing?
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      250bc278
    • Simon Ser's avatar
      tests/kms_chamelium: enable audio test on HDMI ports · 45b6ac9e
      Simon Ser authored
      Now that we have all the required EDID bits in place, we can add a new
      hdmi-audio test.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      45b6ac9e
    • Simon Ser's avatar
      tests/kms_chamelium: disable >48KHz audio tests · f74142d0
      Simon Ser authored
      These weren't tested on DisplayPort (because the Chamelium's default EDID
      doesn't advertise them) so this doesn't remove some test cases.
      
      On HDMI they don't work reliably: sometimes no audio data is captured by the
      Chamelium. This needs to be investigated, but for now let's just disable them.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      f74142d0
    • Simon Ser's avatar
      tests/kms_chamelium: generate an EDID with audio support · 160dd0ff
      Simon Ser authored
      The default Chamelium EDID works great with DisplayPort but has issues with
      HDMI. The EDID advertises itself as a DisplayPort-only device, which causes
      issues with HDMI audio. Additionally, the EDID doesn't contain a magic
      incantation within a vendor-specific data block that is needed for audio to
      work.
      
      This patch makes it so an EDID is generated and set by IGT. The EDID is the
      base IGT EDID patched to append a Short Audio Descriptor and Vendor Specific
      Data block extension.
      
      This generated EDID is suitable for HDMI audio. For DisplayPort audio, we keep
      using the Chamelium's default EDID.
      
      A new enum test_edid has been introduced to prevent mismatches between the
      Chamelium EDID ID and the raw EDID.
      
      The global variable holding the test frequencies has been renamed to prevent
      shadowing by local variables.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      160dd0ff
    • Simon Ser's avatar
      lib/igt_chamelium: add CHAMELIUM_DEFAULT_EDID · 3928be96
      Simon Ser authored
      This ID can be provided to chamelium_port_set_edid to use the default EDID for
      the port.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      3928be96
    • Simon Ser's avatar
      lib/igt_edid: add support for Vendor Specific Data blocks · 0d31a4da
      Simon Ser authored
      For some reason HDMI audio won't work unless you cast a magic IEEE Registration
      Identifier alongside with its appropriate Components of Source Physical
      Address. The easiest way to do this is to capture a wild HDMI EDID, study it,
      and blindly copy bytes because you don't understand anything about their
      possible meaning (if any).
      
      This commit also changes the SAD API exposed by igt_edid, to allow for both a
      SAD block and a VSD block to be included in the same CEA block.
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      0d31a4da
    • Simon Ser's avatar
      lib/igt_edid: add support for Short Audio Descriptors · 52f8b0d1
      Simon Ser authored
      Short Audio Descriptors (SADs) can be wrapped in an EDID extension to advertise
      audio support.
      
      The EDID structure is as follows:
      - The 128-byte EDID block contains a field with the number of 128-byte
        extension blocks that follow.
      - Each extension block has a tag which specifies its type. The tag we're
        interested in is CEA-861.
      - The CEA block has a few flags, including one that indicates whether basic
        audio is supported. The CEA block contains several sub-blocks of variable
        size. There are two types of CEA sub-blocks:
        - Detailed Timing Descriptors (DTDs): additional video timings
        - Data Block Collection: these can detail video, audio, speaker placement and
          other pieces of information about the display.
        We're interested in audio blocks.
      - Audio blocks contain one or more Short Audio Descriptors (SADs). A SAD is a
        3-byte record describing a supported format.
      - SADs can describe support for the PCM format, including sampling rate,
        sample size and channels.
      
      The igt_edid library intentionally exposes all of this complexity because it
      would be nice to generate all kind of valid EDIDs and test the kernel handles
      them correctly (e.g. multiple SADs in different CEA blocks, or any EDID we find
      in the wild really).
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      52f8b0d1
    • Simon Ser's avatar
      tests/kms_chamelium: skip if GetAudioFormat is not supported · ee69b606
      Simon Ser authored
      Skip audio tests in case GetAudioFormat is not supported by the Chamelium
      device (because it is outdated).
      
      A new __chamelium_rpc function has been introduced. The difference with
      chamelium_rpc is that it doesn't asserts that the XML-RPC succeeds.
      
      A new chamelium_supports_get_audio_format function has been introduced. It
      tries to call GetAudioFormats with abritrary parameters, and checks whether the
      call fails because the method doesn't exist. It is not possible to generalize
      it into chamelium_supports_method because some methods might have side-effects
      (and the only way to check whether a method exists is to try to call it).
      Signed-off-by: Simon Ser's avatarSimon Ser <simon.ser@intel.com>
      Cc: Petri Latvala <petri.latvala@intel.com>
      Cc: Arek <arkadiusz.hiler@intel.com>
      Reviewed-by: Arkadiusz Hiler's avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
      ee69b606
    • Petri Latvala's avatar
      Revert "tests/core_unauth_vs_render: new test for the relaxed DRM_AUTH handling" · 0d488fae
      Petri Latvala authored
      The kernel patch for relaxed DRM_AUTH handling caused a regression,
      highlighting bug in the RADV implementation, and was reverted. The
      patch will be reinstated, likely in different form, although until
      then disable the test.
      
      See the thread for details.
      
      https://lists.freedesktop.org/archives/dri-devel/2019-April/215018.html
      
      This reverts commit 90f78ac7.
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110467Signed-off-by: Petri Latvala's avatarPetri Latvala <petri.latvala@intel.com>
      Cc: Emil Velikov <emil.velikov@collabora.com>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Acked-by: 's avatarEmil Velikov <emil.velikov@collabora.com>
      Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> #irc
      0d488fae
  4. 15 May, 2019 4 commits
  5. 14 May, 2019 5 commits
  6. 13 May, 2019 8 commits