drm-howto: fix crtc-selection test

We need to use signed integers so we can compare with -1. Otherwise, this
test doesn't make any sense.

Reported-by: Mark Zhang
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
drm-howto: avoid full modeset if we can reuse an encoder+crtc

Instead of iterating the whole list of encoders+crtcs, we first try the
current encoder+crtc combination when initialization a connector. This
allows to reuse the current setup and just change the framebuffer (if
compatible) instead of doing a full modeset.

Reported-by: Mark Zhang
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>