I installed Ubuntu 17.10 in dual boot. But, in Ubuntu, I could not play sound from the speaker, while headphones worked fine. On Windows, both headphones and speakers worked fine.
So I found this post and applied the suggestion. That is, I opened
sudo gedit /etc/modprobe.d/alsa-base.conf
and I added the following line at the end
options snd-hda-intel model=generic
and then rebooted my PC.
Now the sound is completely broken. I cannot play any sound nor from the speaker nor from the headphones. Now from Ubuntu nor from Windows.
In particular, Windows show the sound icon in the task bar crossed off, and on Device Manager it recognizes an "Intel HD Audio" device, but it has the yellow warning icon next to it and, by opening the properties, it says that the device could not be started due to an error.
I have tried to revert the change and rebooted the PC, but this doesn't work.
What can I do? If I am unable to fix this I had to bring the PC into warranty.
I didn't expect to mess things up SO BAD.