Heavily modified by Benjamin Berg <bberg@redhat.com> to port it to the new libfprint API and adjust the coding style to follow more closely other drivers.