I don't know if anything can be done from here since the cancellation of your visa must be done at the Bahrain airport, not here in Doha.

If your visa is expiring anytime soon, say within the next two to three months, I'm not sure either if your residence permit in Doha would be processed if your Bahrain visa has not been cancelled but has expired.

Let's wait for some additional info from other QLers.