Tap "Start" run regedit.exe, enter the Registry Editor, to the left of the item column to find HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{ 4D36E965-E325-11C E-BFC1-08002BE10318} selected, in the right window find "LowerFilters" item. Right-click to remove it.
Then uninstall the defective optical drive in Device Manager. After uninstalling it, click Scan for hardware changes and it will find the optical drive. The CD-ROM drive will be back to normal.