libgeom: Remove redundant and duplicated code
In g_open(), g_device_path_open().
No functional change.
Sponsored by: Dell EMC Isilon