I have built Intel Media SDK in Ubuntu 16.04 after patching the kernel as given in "http://docs.unified-streaming.com/documentation/capture/media-sdk.html#linux".
When I enter vainfo this is what I get:
libva info: VA-API version 0.99.0
libva info: va_getDriverName() returns 0
libva info: User requested driver 'iHD'
libva info: Trying to open /opt/intel/mediasdk/lib64/iHD_drv_video.so
libva info: Found init function __vaDriverInit_0_32
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 
param: 4, val: 0
libva error: /opt/intel/mediasdk/lib64/iHD_drv_video.so init failed
libva info: va_openDriver() returns 18
vaInitialize failed with error code 18 (invalid parameter),exit
When I run sample_decode, it gives this error:
The processor is Intel(R) Core(TM) i5-6400. Ubuntu 16.04 is run on VMware
Output of uname -r:
This is the kernel that is required. Actually the problem was that I was running Intel Media SDK in VMware with Windows 10 host. I found out that virtual machines cannot access GPU especially when host is windows. That is why HW implementation failed. But why doesn't SW implementation work? I get the same error with SW implementation too.