I have an RPi Zero and am using this: 4inch HDMI LCD - Waveshare Wiki as an HDMI display. The display is not connected to the GPIO pins on the Pi.
Contrary to the description it's not an 800x480 (landscape) screen, instead it's a 480x800 (portrait) screen.
When used with either an X or CLI based linux distro, this isn't a problem, adding the relevant settings to config.txt (noted below) and the screen is rotated and displays as expected. Same with OSX and Windows, it will rotate and work as expected.
hdmi_group=2
hdmi_mode=87
hdmi_cvt 480 800 60 6 0 0 0 dtoverlay=ads7846,cs=1,penirq=25,penirq_pull=2,speed=50000,keep_vref_on=0,swapxy=0,pmax=255,xohms=150,xmin=200,xmax=3900,ymin=200,ymax=3900
display_rotate=3
These are fairly standard and well documented settings, nothing esoteric.
However the problems arises when Kodi launches: Kodi does not respect the rotation correctly.
When launched, although the screen is rotated successfully from a viewer perspective, Kodi still insists on displaying 480x800 and not 800x480 meaning that half of Kodi is cut off vertically, and half of the screen is blank.
To try and resolve before reporting, I've tried setting the resolution in guisettings.xml and in advancedsettings.xml, and running Kodi in a 'window', but this makes no difference as it will not switch to the appropriate resolution. Modifying additional settings in the Pi's config.txt (such as ignoring EDID, etc) do not resolve the issue.
When booting the splash screen displays fine, any console messages are displayed fine... it's all good until Kodi starts.
This is reproducible on v7.95.1 and v7.0.3 as well as other stand-alone Kodi based distros such as OpenElec and OSMC.
Running Kodi inside X (i.e. from within Ubuntu) does not experience this issue, which would strongly imply it's a problem with the standalone builds.