We had mildew in our tub from a buildup of fabric softener and detergent at the waterline.
I had to pop off the top of the washer and the plastic ring around the top of the tub and scrape the funk off the top 3 inches of the tub. stinky. then I did a couple loads of ammonia.
You may have that, and your tub might be flexible plastic that holds a little water.