Real Mallorca’s hopes of avoiding relegation from La Liga were ended on Thursday after they were beaten 2-1 at home to Granada.
Mallorca, who were promoted last season from second-tier Segunda, join Espanyol in being relegated before the final day of the league season on Sunday.
The third spot will be taken by either Leganes or Celta Vigo.
Leganes are a point behind Celta and play at home to Real Madrid, who have already secured the title, on Sunday.
Celta visit bottom-club Espanyol.