Bayer takes over $10bn write-down over weed killer